Advertisement
Uno2K

Aula6 - Numero do Mês

Sep 16th, 2021
963
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.82 KB | None | 0 0
  1. #Código está mal otimizado, mas funciona!
  2. numero_mes = input('Qual o numero do mês: ')
  3. mês = ["Janeiro", "Fevereiro", "Março", "Abril", "Maio", "Junho", "Julho", "Agosto", "Setembro", "Outubro", "Novembro", "Dezembro"]
  4. numero = ['1' ,'2', '3', '4', '5', '6', '7', '8', '9', '10', '11', '12']
  5.  
  6. if numero_mes == "1":
  7.     print("Janeiro")
  8. if numero_mes == "2":
  9.     print("Fevereiro")
  10. if numero_mes == "3":
  11.     print("Março")
  12. if numero_mes == "4":
  13.     print("Abril")
  14. if numero_mes == "5":
  15.     print("Maio")
  16. if numero_mes == "6":
  17.     print("Junho")
  18. if numero_mes == "7":
  19.     print("Julho")
  20. if numero_mes == "8":
  21.     print("Agosto")
  22. if numero_mes == "9":
  23.     print("Setembro")
  24. if numero_mes == "10":
  25.     print("Outubro")
  26. if numero_mes == "11":
  27.     print("Novembro")
  28. if numero_mes == "12":
  29.     print("Dezembro")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement