/ Vijos /

记录详情

Compile Error

foo.cpp: In function 'int main()':
foo.cpp:28:27: error: 'abs' was not declared in this scope
    p=sqr(abs(a[i].x-a[j].x)+abs(a[i].y-a[j].y));
                           ^
foo.cpp:5:18: note: in definition of macro 'sqr'
 #define sqr(x) ((x)*(x))
                  ^
foo.cpp:28:27: note: suggested alternative:
    p=sqr(abs(a[i].x-a[j].x)+abs(a[i].y-a[j].y));
                           ^
foo.cpp:5:18: note: in definition of macro 'sqr'
 #define sqr(x) ((x)*(x))
                  ^
In file included from foo.cpp:2:0:
C:/TDM-GCC-32/lib/gcc/mingw32/4.9.2/include/c++/cmath:99:5: note:   'std::abs'
     abs(_Tp __x)
     ^

信息

递交者
类型
递交
题目
P1474 雷曼兔(csapc)
语言
C++
递交时间
2015-08-27 14:14:28
评测时间
2015-08-27 14:14:29
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes