0_0_19231052_20253.cpp: In function 'int main()':
0_0_19231052_20253.cpp:30:9: error: request for member 'h' in 'i', which is of non-class type 'int'
int h=i.h>
^
0_0_19231052_20253.cpp:31:1: error: expected primary-expression before '=' token
=1;h--){ cnt++; sum+=a[h]; if(sum>j) break; dp[i][j]=max(dp[i][j],dp[h-1][j-sum]+cnt*cnt); } } } printf("%d\n",dp[n][m]); } return 0;}
^
0_0_19231052_20253.cpp:31:7: error: expected ';' before ')' token
=1;h--){ cnt++; sum+=a[h]; if(sum>j) break; dp[i][j]=max(dp[i][j],dp[h-1][j-sum]+cnt*cnt); } } } printf("%d\n",dp[n][m]); } return 0;}
^
|