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_38126170_3594.cpp: In function 'int main()':
0_0_38126170_3594.cpp:95:67: error: no matching function for call to 'distance(int&, int&, int&, int&)'
                 e[cnt].w = distance(a[i].x, a[i].y, a[j].x, a[j].y);
                                                                   ^
0_0_38126170_3594.cpp:95:67: note: candidates are:
0_0_38126170_3594.cpp:29:8: note: double distance(noddd, noddd)
 double distance(noddd at, noddd b){
        ^
0_0_38126170_3594.cpp:29:8: note:   candidate expects 2 arguments, 4 provided
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++/bits/char_traits.h:39,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/ios:40,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/istream:38,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/sstream:38,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/complex:45,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/ccomplex:38,
                 from GCC4.9.2/x86_64-w64-mingw32/include/c++/x86_64-w64-mingw32/bits/stdc++.h:52,
                 from 0_0_38126170_3594.cpp:6:
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_iterator_base_funcs.h:114:5: note: template<class _InputIterator> typename std::iterator_traits<_Iterator>::difference_type std::distance(_InputIterator, _InputIterator)
     distance(_InputIterator __first, _InputIterator __last)
     ^
GCC4.9.2/x86_64-w64-mingw32/include/c++/bits/stl_iterator_base_funcs.h:114:5: note:   template argument deduction/substitution failed:
0_0_38126170_3594.cpp:95:67: note:   candidate expects 2 arguments, 4 provided
                 e[cnt].w = distance(a[i].x, a[i].y, a[j].x, a[j].y);
                                                                   ^


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-05 20:19:05, Gzip enabled