結果

問題 No.522 Make Test Cases(テストケースを作る)
ユーザー brthyyjpbrthyyjp
提出日時 2021-05-09 12:34:38
言語 PyPy3
(7.3.13)
結果
AC  
実行時間 605 ms / 2,000 ms
コード長 217 bytes
コンパイル時間 1,493 ms
コンパイル使用メモリ 81,132 KB
実行使用メモリ 174,192 KB
最終ジャッジ日時 2023-10-18 22:45:29
合計ジャッジ時間 5,677 ms
ジャッジサーバーID
(参考情報)
judge11 / judge12
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 62 ms
72,948 KB
testcase_01 AC 80 ms
79,072 KB
testcase_02 AC 76 ms
77,932 KB
testcase_03 AC 103 ms
84,328 KB
testcase_04 AC 38 ms
51,716 KB
testcase_05 AC 38 ms
51,752 KB
testcase_06 AC 37 ms
51,736 KB
testcase_07 AC 40 ms
52,588 KB
testcase_08 AC 59 ms
67,208 KB
testcase_09 AC 90 ms
81,088 KB
testcase_10 AC 605 ms
174,192 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

n = int(input())
ans = []
for a in range(1, n-1):
    for b in range(a, n-1):
        c = n-a-b
        if c <= 0 or c < b:
            break
        ans.append((a, b, c))
for i in range(len(ans)):
    print(*ans[i])
0