记录详情

Accepted

foo.cc: In function 'int isLeapYear(int)':
foo.cc:5:18: warning: suggest parentheses around '&&' within '||' [-Wparentheses]
    5 |  return year%4==0&&year%100!=0||year%400==0;
      |         ~~~~~~~~~^~~~~~~~~~~~~
foo.cc: In function 'int passDays(int, int, int)':
foo.cc:31:15: warning: unused variable 's' [-Wunused-variable]
   31 |  int m,days=0,s;
      |               ^
foo.cc: In function 'int daysOfYear(int)':
foo.cc:40:14: warning: suggest parentheses around '&&' within '||' [-Wparentheses]
   40 |  if(year%4==0&&year%100!=0||year%400==0)
      |     ~~~~~~~~~^~~~~~~~~~~~~
foo.cc: In function 'int main()':
foo.cc:89:11: warning: unused variable 'm' [-Wunused-variable]
   89 |  int year,m;
      |           ^
正在同步测试数据,请稍后
[Hydro](https://hydro.ac)提供评测服务
# 状态 耗时 内存占用
#1 Accepted 2ms 384.0 KiB
#2 Accepted 1ms 384.0 KiB

信息

递交者
类型
递交
题目
P1007 打印年历
语言
C++
递交时间
2022-07-16 20:23:22
评测时间
2022-07-16 20:23:22
评测机
分数
100
总耗时
4ms
峰值内存
384.0 KiB