結果

問題 No.796 well known
ユーザー stngstng
提出日時 2022-07-02 10:31:09
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 67 ms / 2,000 ms
コード長 174 bytes
コンパイル時間 156 ms
コンパイル使用メモリ 82,176 KB
実行使用メモリ 78,848 KB
最終ジャッジ日時 2024-05-05 08:17:49
合計ジャッジ時間 2,182 ms
ジャッジサーバーID
(参考情報)
judge5 / judge4
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 36 ms
51,712 KB
testcase_01 AC 36 ms
51,712 KB
testcase_02 AC 36 ms
51,968 KB
testcase_03 AC 35 ms
51,456 KB
testcase_04 AC 61 ms
77,056 KB
testcase_05 AC 67 ms
78,336 KB
testcase_06 AC 67 ms
78,848 KB
testcase_07 AC 53 ms
65,408 KB
testcase_08 AC 64 ms
78,464 KB
testcase_09 AC 56 ms
71,936 KB
testcase_10 AC 66 ms
78,464 KB
testcase_11 AC 48 ms
62,976 KB
testcase_12 AC 54 ms
70,272 KB
testcase_13 AC 62 ms
76,544 KB
testcase_14 AC 53 ms
67,200 KB
testcase_15 AC 55 ms
70,784 KB
testcase_16 AC 67 ms
78,848 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

n = int(input())
ans = [1]*n
ans[0] = 3

if sum(ans) % 3 == 0:
    ans[n-1] = 2
elif sum(ans) % 3 == 1:
    ans[n-1] = 1
elif sum(ans) % 3 == 2:
    ans[n-1] = 3

print(*ans)
0