結果

問題 No.2110 012 Matching
ユーザー flygon
提出日時 2022-10-28 21:35:13
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 125 ms / 2,000 ms
コード長 230 bytes
コンパイル時間 262 ms
コンパイル使用メモリ 82,048 KB
実行使用メモリ 76,760 KB
最終ジャッジ日時 2024-07-06 00:39:01
合計ジャッジ時間 2,669 ms
ジャッジサーバーID
(参考情報)
judge5 / judge1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 1
other AC * 11
権限があれば一括ダウンロードができます

ソースコード

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