0_0_37662432_22685.cpp:2:15: error: expected ']' before ';' token
#define N 1010;
^
0_0_37662432_22685.cpp:4:11: note: in expansion of macro 'N'
int chess[N],dp[N];
^
0_0_37662432_22685.cpp:4:12: error: expected unqualified-id before ']' token
int chess[N],dp[N];
^
0_0_37662432_22685.cpp:4:18: error: expected unqualified-id before ']' token
int chess[N],dp[N];
^
0_0_37662432_22685.cpp: In function 'int main()':
0_0_37662432_22685.cpp:17:9: error: 'chess' was not declared in this scope
cin>>chess[i];
^
0_0_37662432_22685.cpp:18:4: error: 'dp' was not declared in this scope
dp[i]=chess[i];
^
0_0_37662432_22685.cpp:24:8: error: 'chess' was not declared in this scope
if(chess[i]>chess[j])
^
0_0_37662432_22685.cpp:26:6: error: 'dp' was not declared in this scope
dp[i]=max(dp[i],dp[j]+chess[i]);
^
0_0_37662432_22685.cpp:29:18: error: 'dp' was not declared in this scope
maxz=max(maxz,dp[i]);
^
|