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_30540261_4180.cpp: In function 'bool ok(int)':
0_0_30540261_4180.cpp:49:1: error: expected primary-expression before '}' token
 }
 ^
0_0_30540261_4180.cpp: In function 'int main()':
0_0_30540261_4180.cpp:7:15: error: expected ')' before '+' token
 #define mid (l+r)/2
               ^
0_0_30540261_4180.cpp:62:23: note: in expansion of macro 'mid'
         int l=1,r=cnt,mid,ans;
                       ^
0_0_30540261_4180.cpp:64:16: error: lvalue required as left operand of assignment
             mid=(l+r)/2;
                ^
0_0_30540261_4180.cpp:65:24: error: 'ans' was not declared in this scope
             if(ok(mid))ans=mid,r=mid-1;
                        ^
0_0_30540261_4180.cpp:68:27: error: 'ans' was not declared in this scope
         printf("%d\n",lsx[ans]);
                           ^


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 06:45:46, Gzip enabled