Main.cc: In function 'int main()': Main.cc:6:9: error: redeclaration of 'int s' int s=4*a; ^ Main.cc:5:9: note: 'int s' previously declared here int s=0; ^