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_16501791_856.cpp:10:13: error: 'int cos' redeclared as different kind of symbol
 int m,n,flo,cos,head,tail,sum_case,sum_edge;
             ^
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_16501791_856.cpp:3:
GCC4.9.2/x86_64-w64-mingw32/include/math.h:139:18: note: previous declaration 'double cos(double)'
   double __cdecl cos(double _X);
                  ^
0_0_16501791_856.cpp: In function 'void addedge(int, int, int, int)':
0_0_16501791_856.cpp:16:2: error: reference to 'next' is ambiguous
  next[sum_edge]=first[x],first[x]=sum_edge;
  ^
0_0_16501791_856.cpp:7:31: note: candidates are: int next [100000]
 int edge[100000],from[100000],next[100000],flow[100000],cost[100000],first[1000];
                               ^
In file included from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_algobase.h:66:0,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/algorithm:61,
                 from 0_0_16501791_856.cpp:3:
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_iterator_base_funcs.h:184:5: note:                 template<class _ForwardIterator> _ForwardIterator std::next(_ForwardIterator, typename std::iterator_traits<_Iter>::difference_type)
     next(_ForwardIterator __x, typename
     ^
0_0_16501791_856.cpp: In function 'void buildgraph()':
0_0_16501791_856.cpp:22:9: error: overloaded function with no contextual type information
  flo=cos=sum_edge=0;
         ^
0_0_16501791_856.cpp: In function 'int mincostmaxflow()':
0_0_16501791_856.cpp:49:37: error: reference to 'next' is ambiguous
    for (int i=first[g[head]];i!=0;i=next[i])
                                     ^
0_0_16501791_856.cpp:7:31: note: candidates are: int next [100000]
 int edge[100000],from[100000],next[100000],flow[100000],cost[100000],first[1000];
                               ^
In file included from GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_algobase.h:66:0,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/algorithm:61,
                 from 0_0_16501791_856.cpp:3:
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_iterator_base_funcs.h:184:5: note:                 template<class _ForwardIterator> _ForwardIterator std::next(_ForwardIterator, typename std::iterator_traits<_Iter>::difference_type)
     next(_ForwardIterator __x, typename
     ^
0_0_16501791_856.cpp:57:11: error: cannot resolve overloaded function 'cos' based on conversion to type 'int'
    return cos;
           ^
0_0_16501791_856.cpp:58:56: error: invalid operands of types '<unresolved overloaded function type>' and 'int' to binary 'operator+'
   flo=flo+f[n+n*m+m+1],cos=cos+f[n+n*m+m+1]*d[n+n*m+m+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-09-29 02:15:13, Gzip enabled