/in/foo.cc:2:1: error: 'cout' does not name a type
cout<<"年份:"<<endl;
^~~~
/in/foo.cc:3:1: error: 'cin' does not name a type
cin>>year;
^~~
/in/foo.cc:4:1: error: 'cout' does not name a type
cout<<"月份:"<<endl;
^~~~
/in/foo.cc:5:1: error: 'cin' does not name a type
cin>>month;
^~~
/in/foo.cc:6:1: error: expected unqualified-id before 'if'
if((year%4==0&&year%100!=0)||year%400==0)//闰年
^~
/in/foo.cc:15:1: error: expected unqualified-id before 'else'
else//平年
^~~~
/in/foo.cc:24:1: error: 'cout' does not name a type
cout<<"天数为:"<<days<<endl;
^~~~
/in/foo.cc:25:1: error: expected unqualified-id before 'return'
return 0;
^~~~~~
/in/foo.cc:26:1: error: expected declaration before '}' token
}
^