Python 练习实例34
题目: 练习函数调用。
程序分析: 无。
实例
!/usr/bin/python
-- coding: UTF-8 --
def hello_world(): print 'hello world' def three_hellos(): for i in range(3): hello_world() if name == 'main': three_hellos()
以上实例输出结果为:
hello world
hello world
hello world
题目: 练习函数调用。
程序分析: 无。
!/usr/bin/python
-- coding: UTF-8 --
def hello_world(): print 'hello world' def three_hellos(): for i in range(3): hello_world() if name == 'main': three_hellos()
以上实例输出结果为:
hello world
hello world
hello world