记录详情

Compile Error

/in/foo.cc: In function 'int main()':
/in/foo.cc:18:29: error: expected ')' before '(' token
 N = (int )malloc(sizeof(int)(n1+n2));
                             ^
/in/foo.cc:18:36: error: cast from 'void*' to 'int' loses precision [-fpermissive]
 N = (int )malloc(sizeof(int)(n1+n2));
                                    ^
/in/foo.cc:18:5: error: invalid conversion from 'int' to 'int*' [-fpermissive]
 N = (int )malloc(sizeof(int)(n1+n2));
     ^~~~~~~~~~~~~~~~~~~~~~~~~
/in/foo.cc:38:11: error: lvalue required as left operand of assignment
 (N + i) = temp;
           ^~~~
/in/foo.cc:47:16: error: ISO C++ forbids comparison between pointer and integer [-fpermissive]
 if ((N + j) == temp)
                ^~~~

信息

递交者
类型
递交
题目
2-3 参赛人数
语言
C++
递交时间
2021-01-28 21:45:13
评测时间
2021-01-28 21:45:13
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes