結果

問題 No.2110 012 Matching
ユーザー flygonflygon
提出日時 2022-10-28 21:35:13
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 167 ms / 2,000 ms
コード長 230 bytes
コンパイル時間 364 ms
コンパイル使用メモリ 87,064 KB
実行使用メモリ 77,844 KB
最終ジャッジ日時 2023-09-20 04:23:26
合計ジャッジ時間 3,713 ms
ジャッジサーバーID
(参考情報)
judge11 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 76 ms
71,476 KB
testcase_01 AC 119 ms
77,344 KB
testcase_02 AC 145 ms
77,844 KB
testcase_03 AC 133 ms
77,284 KB
testcase_04 AC 157 ms
77,300 KB
testcase_05 AC 142 ms
77,504 KB
testcase_06 AC 140 ms
77,532 KB
testcase_07 AC 165 ms
77,748 KB
testcase_08 AC 105 ms
76,940 KB
testcase_09 AC 114 ms
77,452 KB
testcase_10 AC 167 ms
77,456 KB
testcase_11 AC 77 ms
71,404 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys
input = sys.stdin.readline
t = int(input())
for i in range(t):
  a,b,c = map(int,input().split())
  ans = 0
  x = min(a,c)
  ans += x*2 + 2*(b//2)
  b %= 2
  a -= x
  c -= x
  y = min(a,b)
  ans += y + c//2
  print(ans)
0