Advertisement
DerioFT

1118.py

Oct 26th, 2021
86
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.39 KB | None | 0 0
  1. while True:
  2.  
  3. limit = 0
  4. addition = 0
  5.  
  6. while limit < 2:
  7.  
  8. data = float(input())
  9.  
  10. if data >= 0 and data <= 10:
  11.  
  12. addition += data
  13. limit += 1
  14.  
  15. else:
  16. print("nota invalida")
  17.  
  18. print("media = %.2f" % (addition / 2))
  19.  
  20. while True:
  21.  
  22. print("novo calculo (1-sim 2-nao)")
  23.  
  24. data2 = int(input())
  25.  
  26. if data2 == 1 or data2 == 2:
  27. break
  28.  
  29. if data2 == 2:
  30. break
  31.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement