问题描述:函数调用对于很多功能都是必不可少的,下面来练习函数调用。
源代码:
#!/usr/bin/python
# -*- coding: UTF-8 -*-
def hello_world():
print 'hello world'
def three_hellos():
for i in range(5):
hello_world()
if __name__ == '__main__':
five_hellos()
输出结果如下:
hello world
hello world
hello world
hello world
hello world