Compile Error

foo.cc: In function ‘bool cmp(t, t)’:
foo.cc:13:33: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses]
   13 |         return a.x<b.x||a.x==b.x&&a.y<b.y;
      |                         ~~~~~~~~^~~~~~~~~
foo.cc: In function ‘void read()’:
foo.cc:23:16: error: return-statement with a value, in function returning ‘void’ [-fpermissive]
   23 |         return x;
      |                ^
foo.cc:16:15: warning: unused variable ‘f’ [-Wunused-variable]
   16 |         int x,f;
      |               ^
foo.cc: In function ‘int main()’:
foo.cc:29:15: error: void value not ignored as it ought to be
   29 |         n=read();q=read();
      |           ~~~~^~
foo.cc:29:24: error: void value not ignored as it ought to be
   29 |         n=read();q=read();
      |                    ~~~~^~
foo.cc:38:29: error: void value not ignored as it ought to be
   38 |                 int s;s=read();
      |                         ~~~~^~
foo.cc:41:41: error: void value not ignored as it ought to be
   41 |                         int k,l,u;k=read();l=read();
      |                                     ~~~~^~
foo.cc:41:50: error: void value not ignored as it ought to be
   41 |                         int k,l,u;k=read();l=read();
      |                                              ~~~~^~
foo.cc:41:33: warning: unused variable ‘u’ [-Wunused-variable]
   41 |                         int k,l,u;k=read();l=read();
      |                                 ^

信息

递交者
类型
递交
题目
P2433 插入排序
语言
C++
递交时间
2025-07-18 14:45:00
评测时间
2025-07-18 14:45:00
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes