python函数
来源:互联网 发布:cmd获取软件版本号 编辑:程序博客网 时间:2024/06/16 07:34
认识函数
通俗地讲,函数就是功能的意思。函数是用来封装特定功能的。
函数一般分为系统函数和自定义函数两种。
#函数的功能#系统自带的函数#1.实现取字符串长度的功能a="hello my teacher"print len(a)#2.实现字符串的切割a="student"b=a.split("u")print b#3.自定义函数def a(): print "hello";print 777a()
函数的定义
#实例def function1(): a=8 print a
阅读全文
0 0
- python函数
- python 函数
- python 函数
- Python 函数
- python 函数
- PYTHON函数
- python 函数
- Python函数
- python 函数
- Python 函数
- Python 函数
- Python 函数
- python函数
- python函数
- python 函数
- Python 函数
- Python函数
- Python函数
- 当年绑架李嘉诚之子后,张子强与李嘉诚对话的细节
- 计算机网络之路由协议详解
- 自己动手敲的小程序
- Android View的绘制流
- 关于Chrome和IE浏览器解决js修改不即时生效的问题
- python函数
- ROS 使用sick tim561 雷达
- 验证计算和网络服务
- Python开根号
- numpy函数之numpy.ravel
- oKHttp基本封装
- Spring Boot WebMvcConfigurerAdapter 实现拦截器无配置
- Mybatis 打印SQL
- Linux修改/etc/profile文件导致进卡在登陆界面