結果

問題 No.522 Make Test Cases(テストケースを作る)
ユーザー はむ吉🐹はむ吉🐹
提出日時 2017-06-02 22:39:06
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 327 ms / 2,000 ms
コード長 296 bytes
コンパイル時間 1,535 ms
コンパイル使用メモリ 81,408 KB
実行使用メモリ 80,740 KB
最終ジャッジ日時 2023-10-22 00:47:40
合計ジャッジ時間 4,244 ms
ジャッジサーバーID
(参考情報)
judge12 / judge13
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 53 ms
72,632 KB
testcase_01 AC 64 ms
75,828 KB
testcase_02 AC 63 ms
75,764 KB
testcase_03 AC 79 ms
75,944 KB
testcase_04 AC 32 ms
53,496 KB
testcase_05 AC 31 ms
53,496 KB
testcase_06 AC 33 ms
53,496 KB
testcase_07 AC 34 ms
53,496 KB
testcase_08 AC 51 ms
68,432 KB
testcase_09 AC 69 ms
75,860 KB
testcase_10 AC 327 ms
80,740 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#!/usr/bin/env pypy3


def generate(n):
    for a in range(1, n // 3 + 1):
        bc = n - a
        for b in range(a, bc // 2 + 1):
            c = bc - b
            yield a, b, c


def main():
    for res in generate(int(input())):
        print(*res)


if __name__ == '__main__':
    main()
0