Main.cc: In function 'int main()':
Main.cc:23:13: error: 'k' was not declared in this scope
for(k=2*i-1;k>=1;k--){
^
Main.cc:28:13: error: expected '}' at end of input
return 0;
^
Main.cc:28:13: error: expected '}' at end of input