Accepted

foo.cc: In function 'int isLeapYear(int)':
foo.cc:6:18: warning: suggest parentheses around '&&' within '||' [-Wparentheses]
    6 |  return year%4==0&&year%100!=0||year%400==0;
      |         ~~~~~~~~~^~~~~~~~~~~~~
foo.cc: In function 'int passDays(int, int, int)':
foo.cc:32:15: warning: unused variable 's' [-Wunused-variable]
   32 |  int m,days=0,s;
      |               ^
foo.cc: In function 'int daysOfYear(int)':
foo.cc:41:14: warning: suggest parentheses around '&&' within '||' [-Wparentheses]
   41 |  if(year%4==0&&year%100!=0||year%400==0)
      |     ~~~~~~~~~^~~~~~~~~~~~~
foo.cc: In function 'int main()':
foo.cc:62:17: warning: unused variable 'days' [-Wunused-variable]
   62 |  int year,month,days;
      |                 ^~~~
[Hydro](https://hydro.ac)提供评测服务
# 状态 耗时 内存占用
#1 Accepted 6ms 384.0 KiB
#2 Accepted 3ms 384.0 KiB

信息

递交者
类型
递交
题目
P1074 计算星期几
语言
C++
递交时间
2022-07-14 13:07:30
评测时间
2022-07-14 13:07:30
评测机
分数
100
总耗时
10ms
峰值内存
384.0 KiB