#-------------自定义函数 -----------
def myFunction(string):
print string
#使用
myFunction("helloddd")
#--------------自定义有返回的函数--------------
def myFunction(string):
print string
return 1
#使用
a= myFunction("helloddd")
print a
#--------------文档字符串--------------
def myFunction(string):
'''这是第一行 要放在方法定义的下面
这是第三行,第二行要空着接下来的第四五六。。。行不用空了'''
print string
return 1
#使用
print myFunction.__doc__ #第一种
help(myFunction) #第二种