Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
147537 于墨轩 属相 C++ Compile Error 0 MS 0 KB 196 2026-02-05 22:36:29

Tests(0/0):


Code:

#include<iostream> using namespace std; int main(){ int month,day; cin>>month>>day; if(month=1&&day<=24&&1<=month<=12&&1<=day<=31){ cout<<"Pig"; }else{ cout<<"Mouse"; } } return 0; }


Run Info:

Main.cc: In function 'int main()':
Main.cc:6:30: warning: comparison of constant '12' with boolean expression is always true [-Wbool-compare]
 if(month=1&&day<=24&&1<=month<=12&&1<=day<=31){
                              ^
Main.cc:6:23: warning: comparisons like 'X<=Y<=Z' do not have their mathematical meaning [-Wparentheses]
 if(month=1&&day<=24&&1<=month<=12&&1<=day<=31){
                       ^
Main.cc:6:42: warning: comparison of constant '31' with boolean expression is always true [-Wbool-compare]
 if(month=1&&day<=24&&1<=month<=12&&1<=day<=31){
                                          ^
Main.cc:6:37: warning: comparisons like 'X<=Y<=Z' do not have their mathematical meaning [-Wparentheses]
 if(month=1&&day<=24&&1<=month<=12&&1<=day<=31){
                                     ^
Main.cc:6:46: warning: suggest parentheses around assignment used as truth value [-Wparentheses]
 if(month=1&&day<=24&&1<=month<=12&&1<=day<=31){
                                              ^
Main.cc: At global scope:
Main.cc:12:1: error: expected unqualified-id before 'return'
 return 0;
 ^
Main.cc:13:1: error: expected declaration before '}' token
 }
 ^