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_39396111_7902.cpp: In function 'void solve()':
0_0_39396111_7902.cpp:3:13: error: 'longg' was not declared in this scope; did you mean 'long'?
    3 | #define int longg long
      |             ^~~~~
0_0_39396111_7902.cpp:6:5: note: in expansion of macro 'int'
    6 |     int n,s=0,mi=0;
      |     ^~~
0_0_39396111_7902.cpp:7:10: error: 'n' was not declared in this scope
    7 |     cin>>n;
      |          ^
0_0_39396111_7902.cpp:8:15: error: template argument 2 is invalid
    8 |     vector<int>a(n+1);
      |               ^
0_0_39396111_7902.cpp:3:19: error: expected ';' before 'long'
    3 | #define int longg long
      |                   ^~~~
0_0_39396111_7902.cpp:9:9: note: in expansion of macro 'int'
    9 |     for(int i=1;i<=n;i++) cin>>a[i],s+=a[i],mi=max(mi,a[i]);
      |         ^~~
0_0_39396111_7902.cpp:9:17: error: 'i' was not declared in this scope
    9 |     for(int i=1;i<=n;i++) cin>>a[i],s+=a[i],mi=max(mi,a[i]);
      |                 ^
0_0_39396111_7902.cpp:9:37: error: 's' was not declared in this scope
    9 |     for(int i=1;i<=n;i++) cin>>a[i],s+=a[i],mi=max(mi,a[i]);
      |                                     ^
0_0_39396111_7902.cpp:9:45: error: 'mi' was not declared in this scope
    9 |     for(int i=1;i<=n;i++) cin>>a[i],s+=a[i],mi=max(mi,a[i]);
      |                                             ^~
0_0_39396111_7902.cpp:14:13: error: invalid types 'int[int]' for array subscript
   14 |         if(a[1]==a[2]) cout<<"Yes"<<endl;
      |             ^
0_0_39396111_7902.cpp:14:19: error: invalid types 'int[int]' for array subscript
   14 |         if(a[1]==a[2]) cout<<"Yes"<<endl;
      |                   ^
0_0_39396111_7902.cpp:18:12: error: 'mi' was not declared in this scope
   18 |         if(mi>=s-mi) cout<<"Yes"<<endl;
      |            ^~
0_0_39396111_7902.cpp:18:16: error: 's' was not declared in this scope
   18 |         if(mi>=s-mi) cout<<"Yes"<<endl;
      |                ^
0_0_39396111_7902.cpp: In function 'int main()':
0_0_39396111_7902.cpp:3:13: error: 'longg' was not declared in this scope; did you mean 'long'?
    3 | #define int longg long
      |             ^~~~~
0_0_39396111_7902.cpp:24:5: note: in expansion of macro 'int'
   24 |     int t;
      |     ^~~
0_0_39396111_7902.cpp:25:10: error: 't' was not declared in this scope; did you mean 'tm'?
   25 |     cin>>t;
      |          ^
      |          tm


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-09-29 02:47:36, Gzip enabled