結果

問題 No.2233 Average
ユーザー titiatitia
提出日時 2023-03-03 21:52:06
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 125 ms / 2,000 ms
コード長 274 bytes
コンパイル時間 733 ms
コンパイル使用メモリ 81,508 KB
実行使用メモリ 75,608 KB
最終ジャッジ日時 2023-10-18 01:51:23
合計ジャッジ時間 3,484 ms
ジャッジサーバーID
(参考情報)
judge12 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 37 ms
53,336 KB
testcase_01 AC 36 ms
53,336 KB
testcase_02 AC 37 ms
53,336 KB
testcase_03 AC 37 ms
53,336 KB
testcase_04 AC 37 ms
53,336 KB
testcase_05 AC 37 ms
53,336 KB
testcase_06 AC 37 ms
53,336 KB
testcase_07 AC 77 ms
59,496 KB
testcase_08 AC 98 ms
75,604 KB
testcase_09 AC 123 ms
75,588 KB
testcase_10 AC 100 ms
75,532 KB
testcase_11 AC 101 ms
75,496 KB
testcase_12 AC 94 ms
75,532 KB
testcase_13 AC 61 ms
72,512 KB
testcase_14 AC 92 ms
75,544 KB
testcase_15 AC 103 ms
75,552 KB
testcase_16 AC 70 ms
75,500 KB
testcase_17 AC 72 ms
75,492 KB
testcase_18 AC 125 ms
75,608 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys
input = sys.stdin.readline

def calc(a,b,c):
    return (b+c)//2,(a+c)//2,(a+b)//2

T=int(input())
for tests in range(T):
    a,b,c,K=map(int,input().split())

    for i in range(K):
        a,b,c=calc(a,b,c)
        if a==b==c:
            break
    print(a+b+c)
0