結果
問題 |
No.634 硬貨の枚数1
|
ユーザー |
![]() |
提出日時 | 2018-07-16 20:37:43 |
言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
結果 |
AC
|
実行時間 | 330 ms / 2,000 ms |
コード長 | 322 bytes |
コンパイル時間 | 200 ms |
コンパイル使用メモリ | 12,672 KB |
実行使用メモリ | 11,008 KB |
最終ジャッジ日時 | 2024-11-21 13:54:09 |
合計ジャッジ時間 | 13,775 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 75 |
ソースコード
n = int(input()) def f(n): lst = [] i = 0 x = 0 while True: i += 1 x += i if x<n: lst.append(x) elif x==n: return 1 else: break for i in lst: if n-i in lst: return 2 return 3 print(f(n))