F.A.Q
Hand In Hand
Online Acmers
Problem Archive
Realtime Judge Status
Authors Ranklist
 
     C/C++/Java Exams     
ACM Steps
Go to Job
Contest LiveCast
ICPC@China
Best Coder beta
VIP | STD Contests
    DIY | Web-DIY beta
Author ID 
Password 
 Register new ID

View Compilation Error

0_0_26239722_3075.cpp: In function 'int dfs(int, int, int)':
0_0_26239722_3075.cpp:30:61: error: invalid initialization of reference of type 'll& {aka long long int&}' from expression of type 'int'
     if(o) chkmin(res, dfs(o^1, pos+k, k) - v[pos+k] + v[pos]);
                                                             ^
0_0_26239722_3075.cpp:24:13: note: in passing argument 1 of 'void chkmin(ll&, ll)'
 inline void chkmin(ll &x, ll y){ if(y < x) x = y; }
             ^
0_0_26239722_3075.cpp:31:82: error: invalid initialization of reference of type 'll& {aka long long int&}' from expression of type 'int'
     if(o && pos + k < n) chkmin(res, dfs(o^1, pos+k+1, k+1) - v[pos+k+1] + v[pos]);
                                                                                  ^
0_0_26239722_3075.cpp:24:13: note: in passing argument 1 of 'void chkmin(ll&, ll)'
 inline void chkmin(ll &x, ll y){ if(y < x) x = y; }
             ^
0_0_26239722_3075.cpp:32:62: error: invalid initialization of reference of type 'll& {aka long long int&}' from expression of type 'int'
     if(!o) chkmax(res, dfs(o^1, pos+k, k) + v[pos+k] - v[pos]);
                                                              ^
0_0_26239722_3075.cpp:23:13: note: in passing argument 1 of 'void chkmax(ll&, ll)'
 inline void chkmax(ll &x, ll y){ if(y > x) x = y; }
             ^
0_0_26239722_3075.cpp:33:83: error: invalid initialization of reference of type 'll& {aka long long int&}' from expression of type 'int'
     if(!o && pos + k < n) chkmax(res, dfs(o^1, pos+k+1, k+1) + v[pos+k+1] - v[pos]);
                                                                                   ^
0_0_26239722_3075.cpp:23:13: note: in passing argument 1 of 'void chkmax(ll&, ll)'
 inline void chkmax(ll &x, ll y){ if(y > x) x = y; }
             ^


Hangzhou Dianzi University Online Judge 3.0
Copyright © 2005-2024 HDU ACM Team. All Rights Reserved.
Designer & Developer : Wang Rongtao LinLe GaoJie GanLu
Total 0.000000(s) query 1, Server time : 2024-06-21 13:39:48, Gzip enabled