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_39555611_11381.cpp: In function 'void modify(int&, i64, i64, i64, int)':
0_0_39555611_11381.cpp:9:17: error: cannot bind non-const lvalue reference of type 'int&' to a value of type 'i64' {aka 'long long int'}
    9 | #define ls t[k].l
      |            ~~~~~^
0_0_39555611_11381.cpp:25:25: note: in expansion of macro 'ls'
   25 |     if(pos<=mid) modify(ls,l,mid,pos,id);
      |                         ^~
0_0_39555611_11381.cpp:19:18: note:   initializing argument 1 of 'void modify(int&, i64, i64, i64, int)'
   19 | void modify(int &k,i64 l,i64 r,i64 pos,int id)
      |             ~~~~~^
0_0_39555611_11381.cpp:10:17: error: cannot bind non-const lvalue reference of type 'int&' to a value of type 'i64' {aka 'long long int'}
   10 | #define rs t[k].r
      |            ~~~~~^
0_0_39555611_11381.cpp:26:17: note: in expansion of macro 'rs'
   26 |     else modify(rs,mid+1,r,pos,id);
      |                 ^~
0_0_39555611_11381.cpp:19:18: note:   initializing argument 1 of 'void modify(int&, i64, i64, i64, int)'
   19 | void modify(int &k,i64 l,i64 r,i64 pos,int id)
      |             ~~~~~^


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-23 08:24:11, Gzip enabled