一行,包括一个整数,即给定的秒数。
一行,包含三个整数,依次为输入整数对应的小时数、分钟数和秒数(可能为零),中间用一个空格隔开。
3661
1 1 1
x = int(input()) hours = x//3600 minutes = x % 3600 // 60 seconds = x % 60 print(hours, minutes, seconds, sep=" ", end="")
seconds = int(input()) hour = seconds//3600 minute = seconds%3600//60 second = seconds-hour*3600-minute*60 print('{} {} {}'.format(hour,minute,second))
time = int(input()) hour,time = time // 3600,time % 3600 minute,time = time // 60,time % 60 seconds = time print(hour,minute,seconds)
a = input() b = int(a)//3600 c = int(a)%3600//60 d = int(a)%3600%60 print(b,c,d)
seconds = eval(input("")) hours = seconds //3600 minutes = (seconds - hours *3600)//60 second = seconds - (hours*3600) -(minutes*60) print("{} {} {}".format(hours,minutes,second))
这道题你会答吗?花几分钟告诉大家答案吧!
扫描二维码,关注牛客网
下载牛客APP,随时随地刷题