파이썬은 운동 (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