+ 1

I need help with my code, I’m new to this so please help to explain what I should do

Remember, there are 24 hours in a day, 60 minutes in an hour, and 60 seconds in a minute. Use the print() statement to output the result.

14th Jan 2022, 8:04 AM
Mulemwa Willington Mukela
3 odpowiedzi
+ 3
I think it's "Python for beginners 3.2 practice" The task is to display the number of seconds in a month, with some calculations it could be done. Can you show your attempt first?
14th Jan 2022, 8:14 AM
Sousou
Sousou - avatar
+ 1
You will get no help from the community if you don't show us your attempt, but we can help you in understanding the question better, We know that 1 day=24hours And, 1 hours=60 mins that is, the total minutes in one day is 24*60? right?, ok Now, 1 minute = 60 seconds So, 1 day has 24*60*60 seconds, right? Now we have calculated the seconds of one day now you can multiply it by 30 to get your answer simple!
14th Jan 2022, 8:58 AM
NEZ
NEZ - avatar
0
Mulemwa Willington Mukela it should be like this: def seconds_per_day(days): hours = days * 24 minutes = hours * 60 seconds = minutes * 60 return seconds print(seconds_per_day(30))
14th Jan 2022, 12:00 PM
Sousou
Sousou - avatar