Advertisement
Guest User

zadanie 3 v2

a guest
Dec 11th, 2019
127
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.49 KB | None | 0 0
  1. def podajLiczbe(liczba):
  2.     if (liczba < 0):
  3.         return '-1000'
  4.     if (liczba == 0):
  5.         return 'ZEROOOO!!!!'
  6.     if (0 < liczba < 10):
  7.         return liczba
  8.     if (liczba >= 10 and liczba <= 100):
  9.         return "dużo"
  10.     if (liczba > 100):
  11.         return "bardzo dużo"
  12.  
  13.  
  14. while (True):
  15.     try:
  16.         liczba = int(input("Wprowadź liczbę całkowitą: "))
  17.     except ValueError:
  18.         print("To nie jest liczba całkowita")
  19.     break
  20. print(podajLiczbe(liczba))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement