結果

問題 No.2233 Average
ユーザー rlangevinrlangevin
提出日時 2023-03-03 21:42:11
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 129 ms / 2,000 ms
コード長 293 bytes
コンパイル時間 1,349 ms
コンパイル使用メモリ 81,616 KB
実行使用メモリ 75,508 KB
最終ジャッジ日時 2023-10-18 01:38:13
合計ジャッジ時間 3,177 ms
ジャッジサーバーID
(参考情報)
judge13 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 38 ms
53,412 KB
testcase_01 AC 37 ms
53,412 KB
testcase_02 AC 37 ms
53,412 KB
testcase_03 AC 38 ms
53,412 KB
testcase_04 AC 38 ms
53,412 KB
testcase_05 AC 37 ms
53,412 KB
testcase_06 AC 38 ms
53,412 KB
testcase_07 AC 42 ms
59,012 KB
testcase_08 AC 97 ms
75,476 KB
testcase_09 AC 120 ms
75,508 KB
testcase_10 AC 107 ms
75,476 KB
testcase_11 AC 104 ms
75,468 KB
testcase_12 AC 98 ms
75,464 KB
testcase_13 AC 60 ms
70,352 KB
testcase_14 AC 92 ms
75,504 KB
testcase_15 AC 104 ms
75,496 KB
testcase_16 AC 70 ms
75,460 KB
testcase_17 AC 74 ms
75,468 KB
testcase_18 AC 129 ms
75,504 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys
readline = sys.stdin.readline

T = int(readline())
for _ in range(T):
    a, b, c, K = map(int, readline().split())
    while (a != b or b != c) and K:
        A = (a + b)//2
        B = (b + c)//2
        C = (c + a)//2
        K -= 1
        a, b, c = A, B, C
    print(a + b + c)
0