Donggyu1998

Untitled

Jul 22nd, 2021
39
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.48 KB | None | 0 0
  1. while(True):
  2. lottoQuantity = int(input("로또를 몇장 구매하시겠습니까? "))
  3. if lottoQuantity <= 0:
  4. print("종료합니다.")
  5. break
  6. while lottoQuantity>0:
  7. print("랜덤하게 생성된 로또 번호입니다.")
  8. for i in range(1,lottoQuantity+1):
  9. print("[%d]: " % i, end=" ")
  10. for j in range(6):
  11. print("{0:3d}".format(random.randint(1,45)), end=" ")
  12. print()
  13. break
Add Comment
Please, Sign In to add comment