+ 3
Precious time
Ever wondered how many seconds are there in a month (30 days)? Write a program to calculate and output the answer. Answer day= 30 hour = 24*day min = 60*hour Sec = 60*min Print (Sec)
8 Réponses
+ 7
Can you please explain your question.
+ 7
Darkwa John
See ur way of solving the problem is right .
Just make a small change:
Write: print(Sec)
Because u have written P alphabet in capital letter which will show u an error.
+ 4
Darkwa John
What is problem here?
You can do like this also
print(30 * 24 * 60 * 60)
+ 1
There are 24 hours in a day
60 mins in an hour and 60 seconds in a day
Multiplying 24 by day gives hours in a 30days
Multiplying 60 by the hour gives the number of mins in 30days
When you proceed by multiplying 60 by min gives the number of seconds in 30days
+ 1
Ok thanks
+ 1
print("Question : Ever wondered how many seconds are there in a month (30 days)? ")
print("answer:")
print("1 month(30 days) : 30 days")
print("1 day : 24 hours")
print("1 hour : 60 minutes")
print("1 minute : 60 sec")
m = 30 #1 month(30 days)
d = 24 #1 day(24 hours)
h = 60 #1 hour(60 minutes)
min= 60 #1 minute(60 second)
total = m*d*h*min
print(total)
0
And is around 25,920,000
0
Yeah but doing this wont be meaningful to someone
He or she wont know what you’re calculating