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_39077756_28569.cpp: In function 'int main()':
0_0_39077756_28569.cpp:4:25: error: 'inline' specifier invalid for variable 'i' declared at block scope
    4 | #define rep(x,y,z) for (inline int x=(y);(x)<=(z);(x)++)
      |                         ^~~~~~
0_0_39077756_28569.cpp:39:9: note: in expansion of macro 'rep'
   39 |         rep(i,1,n) read(a[i]);
      |         ^~~
0_0_39077756_28569.cpp:4:25: error: 'inline' specifier invalid for variable 'i' declared at block scope
    4 | #define rep(x,y,z) for (inline int x=(y);(x)<=(z);(x)++)
      |                         ^~~~~~
0_0_39077756_28569.cpp:41:9: note: in expansion of macro 'rep'
   41 |         rep(i,1,n) {sum+=a[i];mm=max(mm,sum);}
      |         ^~~
0_0_39077756_28569.cpp:4:25: error: 'inline' specifier invalid for variable 'i' declared at block scope
    4 | #define rep(x,y,z) for (inline int x=(y);(x)<=(z);(x)++)
      |                         ^~~~~~
0_0_39077756_28569.cpp:44:9: note: in expansion of macro 'rep'
   44 |         rep(i,1,n)
      |         ^~~
0_0_39077756_28569.cpp:4:25: error: 'inline' specifier invalid for variable 'i' declared at block scope
    4 | #define rep(x,y,z) for (inline int x=(y);(x)<=(z);(x)++)
      |                         ^~~~~~
0_0_39077756_28569.cpp:52:9: note: in expansion of macro 'rep'
   52 |         rep(i,1,n)
      |         ^~~


Hangzhou Dianzi University Online Judge 3.0
Copyright © 2005-2025 HDU ACM Team. All Rights Reserved.
Designer & Developer : Wang Rongtao LinLe GaoJie GanLu
Total 0.000000(s) query 1, Server time : 2025-02-26 07:08:04, Gzip enabled