Skip to content

Commit

Permalink
Commit
Browse files Browse the repository at this point in the history
  • Loading branch information
Abhijith14 committed Feb 16, 2021
1 parent ca48ecd commit 7b40804
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions MaytoAugust.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
#Q. 17:

#May to August(Control Stmt - if-elif-el)

#The length of a month varies from 30 and 31 days.
#In this exercise you will create a program that reads the name of a month from the user as a string.
#The program should get input from May to August.
#If the input is from may to other months then display error messages as "Invalid"


a=str(input())
if a=="May":
print(31)
elif a=="Jun":
print(30)
elif a=="Jul":
print(31)
elif a=="Aug":
print(30)
else:
print("Invalid")

0 comments on commit 7b40804

Please sign in to comment.