记录详情

Compile Error

/in/foo.cc: In function 'std::istream& operator>>(std::istream&, Number&)':
/in/foo.cc:17:1: warning: no return statement in function returning non-void [-Wreturn-type]
 }
 ^
/in/foo.cc: In function 'int main()':
/in/foo.cc:95:7: error: 'int Number::b' is private within this context
  if(A.b==0||B.b==0)
       ^
/in/foo.cc:6:7: note: declared private here
   int b;
       ^
/in/foo.cc:95:15: error: 'int Number::b' is private within this context
  if(A.b==0||B.b==0)
               ^
/in/foo.cc:6:7: note: declared private here
   int b;
       ^

信息

递交者
类型
自测
题目
P1003 10.10_RationalNumberClass
语言
C++
递交时间
2020-05-08 20:23:36
评测时间
2020-05-08 20:23:36
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes