Using the IDLE development environment, create a Python script named tryme4.py. (Note: an alternative to IDLE is to use a free account on the pythonanywhere website: https://www.pythonanywhere.com/)
IDLE has both an interactive mode and a script mode. You must use the script mode to develop your script. Your script must use meaningful variable names and have comments that describe what is happening in your script. Comments may describe the assignment of a value to a variable, a computation and the assignment of the result to a variable, or the display of the result.
Write a function in this file called nine_lines that uses the function three_lines (provided below) to print a total of nine lines.
TO BE CONTINUE...
def three_lines():
for i in range(3):
print("line")
def nine_lines():
for i in range(3):
three_lines()
nine_lines()
Comments
Leave a comment