Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
96839 只因你太美(Ikun 真爱粉) 青蛙跳台阶 C++ Wrong Answer 0 MS 268 KB 460 2024-11-09 16:51:25

Tests(0/10):


Code:

#include<iostream> // cin\cout\endl #include<cstdio> //scanf()\printf() #include<cstring> // strcpy()\strcat()\strcmp()\strlen()\memset() #include<cmath> //sqrt()\pow()\abs()\ceil()\floor()\max()\min() using namespace std; int main(){ int n,m=0; cin>>n; int a[50]={1,2,4}; for(int i=2;i<=n;i++){ m=0; for(int j=0;j<i;j++){ m+=a[j]; }a[i]=m+1; } cout<<a[n-1]; return 0; }


Run Info:

------Input------
40
------Answer-----
549755813888
------Your output-----
0