foo.cc: In function 'int operator-(const Date&)':
foo.cc:44:9: error: 'year' was not declared in this scope
44 | while (year != date2.year && month != date2.month && day != date2.day)
| ^~~~
foo.cc:44:31: error: 'month' was not declared in this scope
44 | while (year != date2.year && month != date2.month && day != date2.day)
| ^~~~~
foo.cc:44:55: error: 'day' was not declared in this scope
44 | while (year != date2.year && month != date2.month && day != date2.day)
| ^~~
foo.cc:48:13: error: 'daysOfMonth' was not declared in this scope
48 | if (day > daysOfMonth())
| ^~~~~~~~~~~
[Hydro](https://hydro.ac)提供评测服务