Main.cc: In function 'int main()': Main.cc:13:11: error: 'ni' was not declared in this scope for(int i=ni<=m;i++){ s=i+s; ^ Main.cc:13:20: error: expected ';' before ')' token for(int i=ni<=m;i++){ s=i+s; ^