| Run ID | Author | Problem | Lang | Verdict | Score | Time | Memory | Code Length | Submit Time |
|---|---|---|---|---|---|---|---|---|---|
| 111789 | 梁颢城 | 爬楼梯 | C++ | Accepted | 100 | 0 MS | 260 KB | 206 | 2023-11-25 08:07:36 |
#include<bits/stdc++.h> using namespace std; int a[1010] = {1,2}; signed main(){ int n; scanf("%d",&n); for(int i = 2;i < n;i++){ a[i] += a[i-1]+a[i-2]; } printf("%d",a[n-1]); return 0; }