foo.cc:8:3: error: ISO C++ forbids declaration of 'Complex' with no type [-fpermissive]
8 | Complex(){}
| ^~~~~~~
foo.cc:9:3: error: ISO C++ forbids declaration of 'Complex' with no type [-fpermissive]
9 | Complex(int a,int b){real=a;imag=b;}
| ^~~~~~~
foo.cc:10:3: error: 'Complex' does not name a type; did you mean 'Cpmplex'?
10 | Complex plus(Complex a,Complex b)
| ^~~~~~~
| Cpmplex
foo.cc:17:3: error: 'Complex' does not name a type; did you mean 'Cpmplex'?
17 | Complex mult(Complex a,Complex b)
| ^~~~~~~
| Cpmplex
foo.cc: In member function 'int Cpmplex::Complex()':
foo.cc:8:13: warning: no return statement in function returning non-void [-Wreturn-type]
8 | Complex(){}
| ^
foo.cc: In member function 'int Cpmplex::Complex(int, int)':
foo.cc:9:38: warning: no return statement in function returning non-void [-Wreturn-type]
9 | Complex(int a,int b){real=a;imag=b;}
| ^
foo.cc: In function 'int main()':
foo.cc:34:7: error: 'i' was not declared in this scope
34 | for(i=0;i<3;i++){cin>>x[i][0]>>x[i][1];}
| ^
foo.cc:35:3: error: 'Complex' was not declared in this scope; did you mean 'Cpmplex'?
35 | Complex a(x[0][0],x[0][1]),b(x[1][0],x[1][1]),c(x[2][0],x[2][1]),d,e;
| ^~~~~~~
| Cpmplex
foo.cc:36:3: error: 'd' was not declared in this scope
36 | d=d.plus(a,b);e=e.plus(d,c);e.Output();
| ^
foo.cc:36:12: error: 'a' was not declared in this scope
36 | d=d.plus(a,b);e=e.plus(d,c);e.Output();
| ^
foo.cc:36:14: error: 'b' was not declared in this scope
36 | d=d.plus(a,b);e=e.plus(d,c);e.Output();
| ^
foo.cc:36:17: error: 'e' was not declared in this scope
36 | d=d.plus(a,b);e=e.plus(d,c);e.Output();
| ^
foo.cc:36:28: error: 'c' was not declared in this scope
36 | d=d.plus(a,b);e=e.plus(d,c);e.Output();
| ^
[Hydro](https://hydro.ac)提供评测服务