foo.cc: In function 'int main()':
foo.cc:219:2: error: 'cinh1' was not declared in this scope
219 | cinh1>>m1>>s1;
| ^~~~~
foo.cc:222:2: error: 'cinh2' was not declared in this scope
222 | cinh2>>m2>>s2;
| ^~~~~
foo.cc:223:11: error: no matching function for call to 'DateTime::DateTime()'
223 | DateTime tar2,h2,m2,s2);
| ^~~~
foo.cc:181:3: note: candidate: 'DateTime::DateTime(int, int, int)'
181 | DateTime(int h,int m,int s):B(h,m,s){}
| ^~~~~~~~
foo.cc:181:3: note: candidate expects 3 arguments, 0 provided
foo.cc:175:7: note: candidate: 'DateTime::DateTime(DateTime&)'
175 | class DateTime
| ^~~~~~~~
foo.cc:175:7: note: candidate expects 1 argument, 0 provided
foo.cc:223:16: error: conflicting declaration 'DateTime h2'
223 | DateTime tar2,h2,m2,s2);
| ^~
foo.cc:221:8: note: previous declaration as 'int h2'
221 | int h2,m2,s2;
| ^~
foo.cc:223:19: error: conflicting declaration 'DateTime m2'
223 | DateTime tar2,h2,m2,s2);
| ^~
foo.cc:221:11: note: previous declaration as 'int m2'
221 | int h2,m2,s2;
| ^~
foo.cc:223:24: error: expected initializer before ')' token
223 | DateTime tar2,h2,m2,s2);
| ^
foo.cc:221:8: warning: unused variable 'h2' [-Wunused-variable]
221 | int h2,m2,s2;
| ^~
[Hydro](https://hydro.ac)提供评测服务