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_17897199_1179.cpp:12:15: error: 'int fmin [50005]' redeclared as different kind of symbol
 int fmin[max_n],fmax[max_n],smin[max_n],smax[max_n];
               ^
In file included from GCC4.9.2/x86_64-w64-mingw32/include/c++/cmath:44:0,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/random:38,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_algo.h:66,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/algorithm:62,
                 from 0_0_17897199_1179.cpp:3:
GCC4.9.2/x86_64-w64-mingw32/include/math.h:968:25: note: previous declaration 'double fmin(double, double)'
   extern double __cdecl fmin (double, double);
                         ^
0_0_17897199_1179.cpp:12:27: error: 'int fmax [50005]' redeclared as different kind of symbol
 int fmin[max_n],fmax[max_n],smin[max_n],smax[max_n];
                           ^
In file included from GCC4.9.2/x86_64-w64-mingw32/include/c++/cmath:44:0,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/random:38,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_algo.h:66,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/algorithm:62,
                 from 0_0_17897199_1179.cpp:3:
GCC4.9.2/x86_64-w64-mingw32/include/math.h:963:25: note: previous declaration 'double fmax(double, double)'
   extern double __cdecl fmax  (double, double);
                         ^
0_0_17897199_1179.cpp: In function 'int main()':
0_0_17897199_1179.cpp:49:22: error: invalid types '<unresolved overloaded function type>[int]' for array subscript
             fmin[a[i]] = sum(a[i]-1);//在i之前有多少个比它小的数.
                      ^
0_0_17897199_1179.cpp:50:26: error: invalid types '<unresolved overloaded function type>[int]' for array subscript
             ni+=fmin[a[i]];
                          ^
0_0_17897199_1179.cpp:51:22: error: invalid types '<unresolved overloaded function type>[int]' for array subscript
             fmax[a[i]] = i-1-sum(a[i]);//在i之前有多少个比它大的数.
                      ^
0_0_17897199_1179.cpp:52:36: error: invalid types '<unresolved overloaded function type>[int]' for array subscript
             f[i] = f[i-1]+fmax[a[i]];
                                    ^
0_0_17897199_1179.cpp:63:25: error: invalid types '<unresolved overloaded function type>[int]' for array subscript
             ans-=(fmin[i]+smax[i])*(fmax[i]+smin[i]);
                         ^
0_0_17897199_1179.cpp:63:43: error: invalid types '<unresolved overloaded function type>[int]' for array subscript
             ans-=(fmin[i]+smax[i])*(fmax[i]+smin[i]);
                                           ^


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-10-01 09:46:50, Gzip enabled