Advertisement
Jacobacon215

Untitled

Sep 3rd, 2019
99
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.27 KB | None | 0 0
  1. stage = int(input("Stage number: "))
  2. infinite = 0
  3. blocks = 0
  4. while infinite == 0:
  5.     while stage != 0:
  6.         blocks = blocks + stage
  7.         stage = stage - 1
  8.  
  9.     print(blocks)
  10.     stage = int(input("Stage number: "))
  11.     infinite = 0
  12.     blocks = 0
  13. input("done")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement