KC358287

Untitled

Jan 17th, 2021 (edited)
158
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.27 KB | None | 0 0
  1. temp_f = input("Podaj temperaturę w Celsjuszach: ")
  2. if temp_f.isdigit():
  3.     wynik = int(temp_f) * 1.8 + 32
  4.     print(temp_f, " to ", wynik, "w Fahrenheit")
  5. elif temp_f.isalpha():
  6.     print("Temperatura nie może być napisem")
  7. else:
  8.     print("Niepoprawna wartość")
  9.  
Add Comment
Please, Sign In to add comment