Question: Please give the code in python and make sure all parts work. Do it as a beginner. nothing fancy please. do NOT define functions or
Please give the code in python and make sure all parts work. Do it as a beginner. nothing fancy please. do NOT define functions or anything of the sort.
Provide screenshot of code running all scenarios correctly please. thank you.
Exercise Magic Dates points
The date June is special because when it is written in the following format, the
month times the day equals the year:
Design a program that asks the user to enter a month in numeric form a day, and a four
digit year. The program should then determine whether the month times the day equals
the year. If so it should display a message saying the date is magic. Otherwise, it should
display a message saying the date is not magic.
Must check for valid month and month. points
For eg if month is then day can not be points
If it is a leap year, day can be for month of February. points
Allow the user to enter a year between and Verify it is in this range only.
Use the last digits of the year entered for determining if it is a magic date or not, Use the
digit year to determine leap or not.
Hint: You can you use the operator to find the right two digits of the year. See Table
in section
Prints an appropriate response. points
Include various years such as etc. which are leap years and not leap years in
testing to verify your program functions correctly. Include the output as comments in
your program. points
Check for LEAP year: If the year is evenly divisible by to confirm a leap year. If a year
is divisible by but not then it is not a leap year.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
