Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- '''
- Programming Assignnment Unit 4
- University of the People
- CS 1101 - AY2018 - T5
- '''
- #Creates the given number of new lines(defaults to one)
- def new_line(number = 1):
- print('\n' * number)
- #Creates 3 lines by calling the new_line function with an input of 3
- def three_lines():
- new_line(3)
- #Demonstrates a nested function
- def nine_lines():
- print('Now printing nine (9) blank lines:')
- three_lines()
- three_lines()
- three_lines()
- #Clears the screen by printing 25 blank lines(input of 25 to new_line)
- def clear_screen():
- print('Now priting twenty-five (25) blank lines:')
- new_line(25)
- #Call to nine lines
- nine_lines()
- #Call to clear scren
- clear_screen()
Add Comment
Please, Sign In to add comment