Main.cc: In function ‘int main()’:
Main.cc:9:5: error: ‘tongtien’ was not declared in this scope
tongtien = 0;
^~~~~~~~
Main.cc:19:34: error: ‘y’ was not declared in this scope
float tongtien = A * X + B * y;
^
Main.cc:11:10: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result]
scanf("%d", &A);
~~~~~^~~~~~~~~~
Main.cc:13:10: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result]
scanf("%d", &B);
~~~~~^~~~~~~~~~
Main.cc:15:10: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result]
scanf("%f", &X);
~~~~~^~~~~~~~~~
Main.cc:17:10: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result]
scanf("%f", &Y);
~~~~~^~~~~~~~~~