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_30458432_25978.cpp: In function 'int main()':
0_0_30458432_25978.cpp:11:22: error: 'x' was not declared in this scope
         {scanf("%d",&x);
                      ^
0_0_30458432_25978.cpp:12:19: error: 'fn' was not declared in this scope
         if(x){f=x;fn=i}}
                   ^
0_0_30458432_25978.cpp:14:22: error: 'x' was not declared in this scope
         {scanf("%d",&x);
                      ^
0_0_30458432_25978.cpp:15:19: error: 'gn' was not declared in this scope
         if(x){g=x;gn=i}}
                   ^
0_0_30458432_25978.cpp:16:12: error: 'fn' was not declared in this scope
         if(fn==gn){
            ^
0_0_30458432_25978.cpp:16:16: error: 'gn' was not declared in this scope
         if(fn==gn){
                ^
0_0_30458432_25978.cpp:17:26: error: invalid conversion from 'int*' to 'int' [-fpermissive]
             int d=gcd(f,g);
                          ^
0_0_30458432_25978.cpp:5:5: note: initializing argument 1 of 'int gcd(int, int)'
 int gcd(int x,int y){return x?gcd(y%x,x):y;}
     ^
0_0_30458432_25978.cpp:17:26: error: invalid conversion from 'int*' to 'int' [-fpermissive]
             int d=gcd(f,g);
                          ^
0_0_30458432_25978.cpp:5:5: note: initializing argument 2 of 'int gcd(int, int)'
 int gcd(int x,int y){return x?gcd(y%x,x):y;}
     ^
0_0_30458432_25978.cpp:18:32: error: invalid operands of types 'int [1005]' and 'int' to binary 'operator/'
             printf("%d/%d\n",f/d,g/d);
                                ^
0_0_30458432_25978.cpp:18:36: error: invalid operands of types 'int [1005]' and 'int' to binary 'operator/'
             printf("%d/%d\n",f/d,g/d);
                                    ^
0_0_30458432_25978.cpp:20:29: error: 'fi' was not declared in this scope
         else printf("%s\n",(fi>gi)?"1/0":"0/1");
                             ^
0_0_30458432_25978.cpp:20:32: error: 'gi' was not declared in this scope
         else printf("%s\n",(fi>gi)?"1/0":"0/1");
                                ^


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-07-01 06:24:24, Gzip enabled