結果
問題 |
No.1010 折って重ねて
|
ユーザー |
|
提出日時 | 2020-04-16 12:56:34 |
言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
結果 |
AC
|
実行時間 | 34 ms / 2,000 ms |
コード長 | 577 bytes |
コンパイル時間 | 295 ms |
コンパイル使用メモリ | 12,544 KB |
実行使用メモリ | 10,752 KB |
最終ジャッジ日時 | 2024-10-01 19:15:44 |
合計ジャッジ時間 | 2,814 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 43 |
ソースコード
x, y, h = list(map(int, input().split())) count = 0 while True: if x < y: if x > h/1000: x /= 2 h *= 2 count += 1 else: if y > h/1000: y /= 2 h *= 2 count += 1 else: break else: if y > h/1000: y /= 2 h *= 2 count += 1 else: if x > h/1000: x /= 2 h *= 2 count += 1 else: break print(count)