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_25856376_21841.cpp: In function 'void update(int, int)':
0_0_25856376_21841.cpp:32:17: error: invalid initialization of reference of type 'long long int&' from expression of type 'int'
   up(a[i] += val);
                 ^
0_0_25856376_21841.cpp:22:13: note: in passing argument 1 of 'void up(long long int&)'
 inline void up(ll &x) {if (x >= MOD) x -= MOD;}
             ^
0_0_25856376_21841.cpp: In function 'int query(int)':
0_0_25856376_21841.cpp:39:17: error: invalid initialization of reference of type 'long long int&' from expression of type 'int'
   up(sum += a[i]);
                 ^
0_0_25856376_21841.cpp:22:13: note: in passing argument 1 of 'void up(long long int&)'
 inline void up(ll &x) {if (x >= MOD) x -= MOD;}
             ^
0_0_25856376_21841.cpp: In function 'int main()':
0_0_25856376_21841.cpp:59:28: error: invalid initialization of reference of type 'long long int&' from expression of type 'int'
     up(dp[j] = query(v - 1)); 
                            ^
0_0_25856376_21841.cpp:22:13: note: in passing argument 1 of 'void up(long long int&)'
 inline void up(ll &x) {if (x >= MOD) x -= MOD;}
             ^
0_0_25856376_21841.cpp:60:23: error: invalid initialization of reference of type 'long long int&' from expression of type 'int'
     up(ans[i] += dp[j]);  
                       ^
0_0_25856376_21841.cpp:22:13: note: in passing argument 1 of 'void up(long long int&)'
 inline void up(ll &x) {if (x >= MOD) x -= MOD;}
             ^


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-10-06 06:41:48, Gzip enabled