0_0_33377162_10858.cpp: In function 'int main()':
0_0_33377162_10858.cpp:19:15: error: invalid types 'int[int]' for array subscript
dp[cur][k]=max(dp[cur][k],dp[cur^1][k-j*W]+A*j+B);
^
0_0_33377162_10858.cpp:19:30: error: invalid types 'int[int]' for array subscript
dp[cur][k]=max(dp[cur][k],dp[cur^1][k-j*W]+A*j+B);
^
0_0_33377162_10858.cpp:19:47: error: invalid types 'int[int]' for array subscript
dp[cur][k]=max(dp[cur][k],dp[cur^1][k-j*W]+A*j+B);
^
0_0_33377162_10858.cpp:20:27: error: invalid types 'int[int]' for array subscript
ans=max(ans,dp[cur][k]);
^
|