結果

問題 No.1236 長針と短針
ユーザー Coki628Coki628
提出日時 2020-12-02 02:18:10
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 82 ms / 2,000 ms
コード長 903 bytes
コンパイル時間 1,328 ms
コンパイル使用メモリ 87,636 KB
実行使用メモリ 76,208 KB
最終ジャッジ日時 2023-10-11 04:22:21
合計ジャッジ時間 5,418 ms
ジャッジサーバーID
(参考情報)
judge12 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 74 ms
71,796 KB
testcase_01 AC 81 ms
75,996 KB
testcase_02 AC 78 ms
71,744 KB
testcase_03 AC 79 ms
76,008 KB
testcase_04 AC 78 ms
71,740 KB
testcase_05 AC 76 ms
71,644 KB
testcase_06 AC 82 ms
76,012 KB
testcase_07 AC 79 ms
75,976 KB
testcase_08 AC 80 ms
76,208 KB
testcase_09 AC 78 ms
71,824 KB
testcase_10 AC 75 ms
71,748 KB
testcase_11 AC 79 ms
75,956 KB
testcase_12 AC 74 ms
71,804 KB
testcase_13 AC 79 ms
75,968 KB
testcase_14 AC 77 ms
71,760 KB
testcase_15 AC 75 ms
71,520 KB
testcase_16 AC 79 ms
76,112 KB
testcase_17 AC 80 ms
76,124 KB
testcase_18 AC 76 ms
71,792 KB
testcase_19 AC 80 ms
76,020 KB
testcase_20 AC 79 ms
75,976 KB
testcase_21 AC 75 ms
71,656 KB
testcase_22 AC 77 ms
75,980 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys

def input(): return sys.stdin.readline().strip()
def list2d(a, b, c): return [[c] * b for i in range(a)]
def list3d(a, b, c, d): return [[[d] * c for k in range(b)] for i in range(a)]
def list4d(a, b, c, d, e): return [[[[e] * d for k in range(c)] for k in range(b)] for i in range(a)]
def ceil(x, y=1): return int(-(-x // y))
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(N=None): return list(MAP()) if N is None else [INT() for i in range(N)]
def Yes(): print('Yes')
def No(): print('No')
def YES(): print('YES')
def NO(): print('NO')
sys.setrecursionlimit(10**9)
INF = 10**19
MOD = 10**9 + 7
EPS = 10**-10

h, m = MAP()

mod = 12*60*60

hms = (h*60+m)*60
ms = 12*m*60
ans = 0
while 1:
    res1 = hms % mod
    res2 = ms % mod
    # print(res1, res2)
    if abs(res1-res2) < 11:
        print(ans)
        break
    ms += 12
    hms += 1
    ans += 1
0