結果

問題 No.70 睡眠の重要性!
ユーザー akitsugu777akitsugu777
提出日時 2018-10-23 13:26:18
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 45 ms / 5,000 ms
コード長 281 bytes
コンパイル時間 87 ms
コンパイル使用メモリ 12,544 KB
実行使用メモリ 12,672 KB
最終ジャッジ日時 2024-04-29 20:49:59
合計ジャッジ時間 942 ms
ジャッジサーバーID
(参考情報)
judge2 / judge4
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 44 ms
12,672 KB
testcase_01 AC 45 ms
12,416 KB
testcase_02 AC 43 ms
12,416 KB
testcase_03 AC 43 ms
12,544 KB
testcase_04 AC 41 ms
12,544 KB
testcase_05 AC 42 ms
12,416 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import datetime

n = int(input())

x = 0
for i in range(n):
    t = input().split()
    t0 = datetime.datetime.strptime(t[0], '%H:%M')
    t1 = datetime.datetime.strptime(t[1], '%H:%M')
    t2 = t1 - t0
    h, m = divmod(t2.seconds//60, 60)
    m += h * 60
    x += m
    
print(x)
0