subject
Computers and Technology, 06.04.2021 08:20 dej33

Can find error , suppose to print what season it is and if fails : Traceback (most recent call last): File "main. py", line 4, in

input_month = input()

EOFError: EOF when reading a line

Here's the code .

input_month = input()
input_day = int(input())

input_month = input()
input_day = int(input())

if input_month in ('January', 'February', 'March'):
season = 'winter'

elif input_month in ('April', 'May', 'June'):
season = 'spring'

elif input_month in ('July', 'August', 'September'):
season = 'summer'

else:
season = 'autumn'

if (input_month == 'March') and (input_day > 19):
season = 'spring'
elif (input_month == 'June') and (input_day > 20):
season = 'summer'
elif (input_month == 'September') and (input_day > 21):
season = 'autumn'
elif (input_month == 'December') and (input_day > 20):
season = 'winter'

print("Season is",season)

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 07:00
Robots with telescoping arms are sometimes used to perform tasks (e.g., welding or placing screws) where access may be difficult for other robotic types. during a test run, a robot arm is programmed to extend according to the relationship r = 3 + 0.5cos(4θ) and the arm rotates according to the relationship θ=−π4t2+πt , where r is in feet, θ is in radians, and t is in seconds. use a computer program to plot the path of tip a in x and y coordinates for 0 ≤ t ≤ 4s.
Answers: 2
question
Computers and Technology, 23.06.2019 06:00
Which statistical function in a spreadsheet you to see how far each number varies, on average, from the average value of the list?
Answers: 2
question
Computers and Technology, 23.06.2019 15:00
Jake really works well with numbers and is skilled with computers but doesn't work well with others. which of the jobs discussed in this unit might be best for jake? why?
Answers: 3
question
Computers and Technology, 23.06.2019 16:00
Write a grading program for a class with the following grading policies: a. there are two quizzes, each graded on the basis of 10 points. b. there is one midterm exam and one final exam, each graded on the basis of 100 points. c. the final exam counts for 50% of the grade, the midterm counts for 25%, and the two quizzes together count for a total of 25%. (do not forget to normalize the quiz scores. they should be converted to a percentage before they are averaged in.) any grade of 90 or more is an a, any grade of 80 or more (but less than 90) is a b, any grade of 70 or more (but less than 80) is a c, any grade of 60 or more (but less than 70) is a d, and any grade below 60 is an f. the program will read in the student’s scores and output the student’s record, which consists of two quiz and two exam scores as well as the student’s average numeric score for the entire course and final letter grade. define and use a structure for the student reco
Answers: 2
You know the right answer?
Can find error , suppose to print what season it is and if fails : Traceback (most recent call last)...
Questions
question
Mathematics, 06.05.2020 04:26
question
Mathematics, 06.05.2020 04:26