結果
問題 | No.70 睡眠の重要性! |
ユーザー | ixmel |
提出日時 | 2017-03-30 16:43:05 |
言語 | Python3 (3.12.2 + numpy 1.26.4 + scipy 1.12.0) |
結果 |
AC
|
実行時間 | 17 ms / 5,000 ms |
コード長 | 335 bytes |
コンパイル時間 | 66 ms |
コンパイル使用メモリ | 10,568 KB |
実行使用メモリ | 7,988 KB |
最終ジャッジ日時 | 2023-09-21 08:43:00 |
合計ジャッジ時間 | 771 ms |
ジャッジサーバーID (参考情報) |
judge15 / judge12 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | AC | 15 ms
7,984 KB |
testcase_01 | AC | 15 ms
7,960 KB |
testcase_02 | AC | 17 ms
7,960 KB |
testcase_03 | AC | 16 ms
7,988 KB |
testcase_04 | AC | 17 ms
7,904 KB |
testcase_05 | AC | 17 ms
7,932 KB |
ソースコード
import sys import math as mas n=int(input()) sum=0 for i in range(n): s=input() a,b=map(str,s.split()) c=list(map(int,a.split(':'))) fro=c[0]*60+c[1] c=list(map(int,b.split(':'))) to=c[0]*60+c[1] if fro<to:sum+=to-fro else:sum+=24*60-fro+to print(sum) #for i in sys.stdin: # a,b=map(int,i.split()) # print(gcd(a,b),lcm(a,b))