Borderou de evaluare (job #2343748)

Utilizator GeorgeCalinPetruta George-Calin GeorgeCalin Data 14 februarie 2019 12:24:56
Problema Rating Status done
Runda Arhiva de probleme Compilator cpp-64 | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: main.cpp: In function 'int main()': main.cpp:33:39: error: no matching function for call to 'sort(std::vector<duet>::iterator, <unresolved overloaded function type>, bool (&)(duet, duet))' sort(v[i].begin(),v[i].end,cmp); ^ In file included from /usr/include/c++/6/algorithm:62:0, from main.cpp:3: /usr/include/c++/6/bits/stl_algo.h:4697:5: note: candidate: template<class _RAIter> void std::sort(_RAIter, _RAIter) sort(_RandomAccessIterator __first, _RandomAccessIterator __last) ^~~~ /usr/include/c++/6/bits/stl_algo.h:4697:5: note: template argument deduction/substitution failed: main.cpp:33:39: note: could not resolve address from overloaded function 'v[i].std::vector<duet>::end' sort(v[i].begin(),v[i].end,cmp); ^ In file included from /usr/include/c++/6/algorithm:62:0, from main.cpp:3: /usr/include/c++/6/bits/stl_algo.h:4727:5: note: candidate: template<class _RAIter, class _Compare> void std::sort(_RAIter, _RAIter, _Compare) sort(_RandomAccessIterator __first, _RandomAccessIterator __last, ^~~~ /usr/include/c++/6/bits/stl_algo.h:4727:5: note: template argument deduction/substitution failed: main.cpp:33:39: note: could not resolve address from overloaded function 'v[i].std::vector<duet>::end' sort(v[i].begin(),v[i].end,cmp); ^ main.cpp:35:24: error: 'class std::vector<duet>' has no member named 'p' fout<<v[i].p<<" "; ^ Non zero exit status: 1

Ceva nu functioneaza?