結果

問題 No.91 赤、緑、青の石
ユーザー rlangevinrlangevin
提出日時 2023-01-22 02:14:34
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 325 bytes
コンパイル時間 397 ms
コンパイル使用メモリ 87,304 KB
実行使用メモリ 77,104 KB
最終ジャッジ日時 2023-09-06 12:50:53
合計ジャッジ時間 17,117 ms
ジャッジサーバーID
(参考情報)
judge11 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 800 ms
77,032 KB
testcase_01 AC 539 ms
76,940 KB
testcase_02 AC 744 ms
77,100 KB
testcase_03 AC 638 ms
77,040 KB
testcase_04 AC 708 ms
77,032 KB
testcase_05 AC 685 ms
77,012 KB
testcase_06 AC 476 ms
77,056 KB
testcase_07 AC 71 ms
71,292 KB
testcase_08 AC 71 ms
71,456 KB
testcase_09 AC 71 ms
71,576 KB
testcase_10 AC 71 ms
71,460 KB
testcase_11 AC 748 ms
77,020 KB
testcase_12 AC 778 ms
76,996 KB
testcase_13 AC 557 ms
76,900 KB
testcase_14 AC 662 ms
76,884 KB
testcase_15 AC 800 ms
76,940 KB
testcase_16 AC 72 ms
71,400 KB
testcase_17 WA -
testcase_18 AC 72 ms
71,356 KB
testcase_19 AC 72 ms
71,272 KB
testcase_20 AC 72 ms
71,508 KB
testcase_21 AC 72 ms
71,352 KB
testcase_22 AC 72 ms
71,188 KB
testcase_23 AC 72 ms
71,524 KB
testcase_24 AC 72 ms
71,480 KB
testcase_25 AC 860 ms
76,968 KB
testcase_26 AC 840 ms
77,036 KB
testcase_27 AC 922 ms
77,024 KB
testcase_28 AC 780 ms
77,104 KB
testcase_29 AC 539 ms
76,964 KB
testcase_30 AC 805 ms
76,964 KB
testcase_31 AC 846 ms
76,976 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

def f(a, b, c):
    L = [a, b, c]
    if min(L) < 0:
        return 0
    L.sort()
    v = (L[-1] - L[0])//3
    L[-1] -= 2 * v
    L[0] += v
    return L

R, G, B = map(int, input().split())
L = [R, G, B]
L.sort()
R, G, B = L
ans = 0
for i in range(B//2):
    X = f(R + i, G, B - 2 * i)
    ans = max(ans, min(X))
print(ans)
0