Python Exercise Example 34
**Problem:** Practice function calls.
**Program analysis:** Use a function to output three times RUNOOB The string.
Example
#!/usr/bin/python
-- coding: UTF-8 --
def
hello_runoob
(
)
:
(
'
RUNOOB
'
)
def
hello_runoobs
(
)
:
for
i
in
range
(
3
)
:
hello_runoob
(
)
if
name
==
'
main
'
:
hello_runoobs
(
)
The output of the above example is:
RUNOOB
RUNOOB
RUNOOB
Python 100 Examples