Compile Error

foo.cc: In function 'int main()':
foo.cc:6:13: error: 'mouth' was not declared in this scope
  cin>>year>>mouth;
             ^~~~~
foo.cc:6:13: note: suggested alternative: 'month'
  cin>>year>>mouth;
             ^~~~~
             month
foo.cc:9:34: error: invalid operands of types 'void*' and 'int' to binary 'operator%'
   if(year%400==0||(year%4==&&year%100!==0))
                            ~~~~~~^~~~
foo.cc:9:40: error: expected primary-expression before '=' token
   if(year%400==0||(year%4==&&year%100!==0))
                                        ^
foo.cc:18:4: error: expected '}' before 'else'
    else if(mouth==1||mouth==3||mouth==5||mouth==7||mouth==8||mouth==10||mouth==12) 
    ^~~~
foo.cc:5:11: warning: unused variable 'month' [-Wunused-variable]
  int year,month,days;
           ^~~~~
foo.cc:9:30: error: label 'year' used but not defined
   if(year%400==0||(year%4==&&year%100!==0))
                              ^~~~
[Hydro](https://hydro.ac)提供评测服务

信息

递交者
类型
递交
题目
P1023 某月的天数
语言
C++
递交时间
2021-11-28 18:34:34
评测时间
2021-11-28 18:34:34
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes