/ Vijos /

记录详情

Compile Error

/in/foo.cc: In function 'int main()':
/in/foo.cc:102:37: error: invalid operands of types '__gnu_cxx::__enable_if<true, double>::__type {aka double}' and 'int' to binary 'operator%'
    if(A==0&&B!=0)ans+=abs(tr[B].d-x)%1000000,del(tr[B].d);
                       ~~~~~~~~~~~~~~^~~~~~~~
/in/foo.cc:103:42: error: invalid operands of types '__gnu_cxx::__enable_if<true, double>::__type {aka double}' and 'int' to binary 'operator%'
    else if(B==0&&A!=0)ans+=abs(tr[A].d-x)%1000000,del(tr[A].d);
                            ~~~~~~~~~~~~~~^~~~~~~~
/in/foo.cc:106:57: error: invalid operands of types '__gnu_cxx::__enable_if<true, double>::__type {aka double}' and 'int' to binary 'operator%'
     if(abs(tr[B].d-x)>abs(tr[A].d-x))ans+=abs(tr[A].d-x)%1000000,del(tr[A].d);
                                           ~~~~~~~~~~~~~~^~~~~~~~
/in/foo.cc:107:29: error: invalid operands of types '__gnu_cxx::__enable_if<true, double>::__type {aka double}' and 'int' to binary 'operator%'
     else ans+=abs(tr[B].d-x)%1000000,del(tr[B].d);
               ~~~~~~~~~~~~~~^~~~~~~~

信息

递交者
类型
自测
题目
P1001 谁拿了最多奖学金
语言
C++
递交时间
2019-07-14 18:15:39
评测时间
2019-07-14 18:15:39
评测机
分数
0
总耗时
0ms
峰值内存
0 Bytes