foo.cc: In function 'int IsLeapYear(int)':
foo.cc:8:30: warning: suggest parentheses around '&&' within '||' [-Wparentheses]
if(year%400==0 || year%4==0 && year%100!=0)
~~~~~~~~~~^~~~~~~~~~~~~~
foo.cc: In function 'int WeekdayOfTheFirstDay(int, int)':
foo.cc:58:6: warning: unused variable 'a' [-Wunused-variable]
int a,b,c,i,j,y,n,z,sum=0;
^
foo.cc:58:10: warning: unused variable 'c' [-Wunused-variable]
int a,b,c,i,j,y,n,z,sum=0;
^
foo.cc: In function 'int main()':
foo.cc:95:11: warning: unused variable 'month' [-Wunused-variable]
int year,month,i,c,j,d,b,k;
^~~~~
foo.cc:95:25: warning: unused variable 'b' [-Wunused-variable]
int year,month,i,c,j,d,b,k;
^
foo.cc: In function 'int DaysOfMonth(int, int)':
foo.cc:54:1: warning: control reaches end of non-void function [-Wreturn-type]
}
^
[Hydro](https://hydro.ac)提供评测服务