0

HELP ME, PLEASE (Python)

2)A timestamp is three numbers: a number of hours, minutes and seconds. Given two timestamps, calculate how many seconds is between them. The moment of the first timestamp occurred before the moment of the second timestamp.( 6, 1, 30, 6, 2, 10 result 40 sec.) How i can solve this?

30th Apr 2020, 4:52 PM
_nrkvv_
_nrkvv_ - avatar
2 Answers
0
hour = int(input()) minute = int(input()) second = int(input()) hour2 = int(input()) minute2 = int(input()) second2 = int(input()) total = hour * 3600 + minute * 60 + second total2 = hour2 * 3600 + minute2 * 60 + second2 print(total2 - total)
30th Mar 2023, 5:30 PM
Zinc Nguyen
Zinc Nguyen - avatar