Advertisement
teslariu

horoscopo

Oct 19th, 2021
180
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.87 KB | None | 0 0
  1. #!/usr/bin/env python
  2. # -*- coding: utf-8 -*-
  3. #
  4. """
  5. Script que pregunta un dia del mes y un nro de mes y responde con su
  6. signo del horóscopo
  7. Ej:
  8. >>> Ingrese el mes de su nacimiento (del 1 al 12): 4
  9. >>> Ingrese el día de su nacimiento (del 1 al 31): 7
  10. >>> Aries
  11. ARIES
  12. 21/03 - 19/04
  13.  
  14. TAURO
  15. 20/04 - 20/05
  16.  
  17. GÉMINIS
  18. 21/05 - 20/06
  19.  
  20. CÁNCER
  21. 21/06 - 22/07
  22.  
  23. LEO
  24. 23/07 - 22/08
  25.  
  26. VIRGO
  27. 23/08 - 22/09
  28.  
  29. LIBRA
  30. 23/09 - 22/10
  31.  
  32. ESCORPIO
  33. 23/10 - 21/11
  34.  
  35. SAGITARIO
  36. 22/11 - 21/12
  37.  
  38. CAPRICORNIO
  39. 22/12 - 19/01
  40.  
  41. ACUARIO
  42. 20/01 - 18/02
  43.  
  44. PISCIS
  45. 19/02 - 20/03
  46.  
  47. """
  48. mes = input("Ingrese el mes de su nacimiento (del 1 al 12): ")
  49. dia = int(input("Ingrese el día de su nacimiento (del 1 al 31): "))
  50.  
  51. if (mes=="12" and 21<dia<32) or (mes=="1" and  0<dia<20):
  52.     print("Capricornio")
  53.    
  54. elif (mes=="1" and 20<=dia<=31) or (mes=="2" and  1<=dia<=18):
  55.     print("Acuario")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement