0_0_26161161_13622.cpp: In function 'int main()':
0_0_26161161_13622.cpp:17:9: error: 'i' was not declared in this scope
for(i=0;i<2001;i++)for(j=0;j<1001;j++)dp[i][j]=Max;
^
0_0_26161161_13622.cpp:18:6: error: 'i' was not declared in this scope
for(i=n-1;i>=0;i--)for(j=0;j<i;j++)if(a[j]>=a[j+1]){a[j]+=a[j+1];a[j+1]=a[j]-a[j+1];a[j]-=a[j+1];};
^
0_0_26161161_13622.cpp:19:10: error: 'i' was not declared in this scope
for (i=1;i<=n;i++)dp[i][0]=0;dp[0][0]=0;
^
0_0_26161161_13622.cpp:21:8: error: 'i' was not declared in this scope
for(i=2;i<=n;i++)for(j=1;j<=i/2;j++)dp[i][j]=f(dp[i-1][j],dp[i-2][j-1]+(a[i]-a[i-1])*(a[i]-a[i-1]));
^
|