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_38754938_27254.cpp: In function 'void update(long long int&, long long int, long long int, long long int)':
0_0_38754938_27254.cpp:54:17: error: cannot bind non-const lvalue reference of type 'long long int&' to a value of type 'int'
   54 | #define ls t[p].lc
      |            ~~~~~^~
0_0_38754938_27254.cpp:77:25: note: in expansion of macro 'ls'
   77 |     if(mid >= x) update(ls, L, mid, x);
      |                         ^~
0_0_38754938_27254.cpp:66:18: note:   initializing argument 1 of 'void update(long long int&, long long int, long long int, long long int)'
   66 | void update(int &p, int L, int R, int x) {
      |                  ^
0_0_38754938_27254.cpp:55:17: error: cannot bind non-const lvalue reference of type 'long long int&' to a value of type 'int'
   55 | #define rs t[p].rc
      |            ~~~~~^~
0_0_38754938_27254.cpp:78:17: note: in expansion of macro 'rs'
   78 |     else update(rs, mid + 1, R, x);
      |                 ^~
0_0_38754938_27254.cpp:66:18: note:   initializing argument 1 of 'void update(long long int&, long long int, long long int, long long int)'
   66 | void update(int &p, int L, int R, int x) {
      |                  ^
0_0_38754938_27254.cpp: In function 'void dfs(long long int)':
0_0_38754938_27254.cpp:94:22: error: cannot bind non-const lvalue reference of type 'long long int&' to a value of type 'int'
   94 |         update(root[x], 1, n, SAM::endpos[x]);
      |                ~~~~~~^
0_0_38754938_27254.cpp:66:18: note:   initializing argument 1 of 'void update(long long int&, long long int, long long int, long long int)'
   66 | void update(int &p, int L, int R, int x) {
      |                  ^


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-11-26 12:12:24, Gzip enabled