結果
問題 |
No.522 Make Test Cases(テストケースを作る)
|
ユーザー |
![]() |
提出日時 | 2025-03-20 21:00:55 |
言語 | PyPy3 (7.3.15) |
結果 |
AC
|
実行時間 | 248 ms / 2,000 ms |
コード長 | 323 bytes |
コンパイル時間 | 193 ms |
コンパイル使用メモリ | 82,768 KB |
実行使用メモリ | 155,572 KB |
最終ジャッジ日時 | 2025-03-20 21:01:00 |
合計ジャッジ時間 | 4,058 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 11 |
ソースコード
N = int(input()) output = [] max_a = N // 3 for a in range(1, max_a + 1): remainder = N - a max_b = remainder // 2 min_b = a # Iterate through possible b values for b in range(min_b, max_b + 1): c = N - a - b if c >= b: output.append(f"{a} {b} {c}") print('\n'.join(output))