結果
| 問題 | 
                            No.45 回転寿司
                             | 
                    
| ユーザー | 
                             | 
                    
| 提出日時 | 2023-12-12 23:28:39 | 
| 言語 | Python3  (3.13.1 + numpy 2.2.1 + scipy 1.14.1)  | 
                    
| 結果 | 
                             
                                WA
                                 
                             
                            
                         | 
                    
| 実行時間 | - | 
| コード長 | 139 bytes | 
| コンパイル時間 | 481 ms | 
| コンパイル使用メモリ | 12,800 KB | 
| 実行使用メモリ | 10,880 KB | 
| 最終ジャッジ日時 | 2024-09-27 05:05:08 | 
| 合計ジャッジ時間 | 2,493 ms | 
| 
                            ジャッジサーバーID (参考情報)  | 
                        judge3 / judge1 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| sample | AC * 2 WA * 2 | 
| other | AC * 6 WA * 24 | 
ソースコード
N=int(input())
V=list(map(int,input().split()))
A=[0 for i in range(N)]
for i in range(1,N):
    A[i]=max(A[i-1],A[i-2]+V[i])
print(A[N-1])