记录详情

Compile Error

/in/foo.cc:18:13: error: expected ':' before 'show'
   18 |      private show() const {
      |             ^~~~~
      |             :
/in/foo.cc:18:14: error: ISO C++ forbids declaration of 'show' with no type [-fpermissive]
   18 |      private show() const {
      |              ^~~~
/in/foo.cc: In member function 'int Time::show() const':
/in/foo.cc:20:5: warning: no return statement in function returning non-void [-Wreturn-type]
   20 |     }
      |     ^
/in/foo.cc: In function 'int main()':
/in/foo.cc:28:11: error: 'int Time::show() const' is private within this context
   28 |     t.show();
      |     ~~~~~~^~
/in/foo.cc:18:14: note: declared private here
   18 |      private show() const {
      |              ^~~~

信息

递交者
类型
递交
题目
P1009 contest1-1 时间类Time
比赛
2026-11-13 C++实测1
语言
C++
递交时间
2026-11-13 20:38:32
评测时间
2026-11-13 20:38:32
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes