Answered step by step
Verified Expert Solution
Question
1 Approved Answer
The objective of this program is to test your ability to perform Python arithmetic, input / output , decision, and repetition statements.Description:The following algorithm will
The objective of this program is to test your ability to perform Python arithmetic, inputoutput decision, and repetition statements.Description:The following algorithm will calculate the date of Easter for any year in the twentieth or twentyfirst centuries for Western dates. Valid years are to Have the user input a positive year.Subtract from the user input year and call the difference valueD.Divide valueD by and call the remainder valueR.Divide valueR by Discard the remainder and call the quotient valueP.Divide valueR valueP by and call the remainder valueS.Divide valueD by Discard the remainder and call the quotient valueQ.Divide valueD valueQ valueS by and call the remainder valueT.Easter is on valueS valueT If this result is greater than zero, Easter for that year occurs in April on that date.If the result is zero or negative Easter for that year falls in March. If the result is Easter for that year falls on March If the result is Easter occurs on March If the result is Easter occurs on March etc. Hint: What happens when you subtract a negative number from a number as in Assignment:Write a program, name it Easter.py that will ask the user to input a year and calculate the date of Easter for that year. You may need to verify your programs accuracy by doing each step by hand then check your programs values at that point. Your program should produce a single line of output of the form:Western Easter Sunday March, Assume the user always inputs a valid year.Once your program outputs, it should loop back to the beginning and ask the user for another year. If the user inputs a negative year, stop the program, and say ByeSome sample dates:th April th April th March th April th March th April th April th April th April th April th April th March st March
On
the left is my codes for the program and on the right is where i ran the program. However eveytime i run the program i get a error message. Please help me correct my codes and figure out what i did wrong
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started