Main.cc:2:6: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type] main() ^ Main.cc: In function 'int main()': Main.cc:12:18: warning: too many arguments for format [-Wformat-extra-args] printf("%d",b,c,d); ^ Main.cc:12:19: error: expected '}' at end of input printf("%d",b,c,d); ^ Main.cc:6:15: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result] scanf("%d",&a); ^