Borderou de evaluare (job #2503505)

Utilizator etienAndrone Stefan etien Data 3 decembrie 2019 12:14:27
Problema Expresie2 Status done
Runda Arhiva de probleme Compilator cpp-64 | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: main.cpp: In function 'long long int expresieparpat()': main.cpp:110:46: error: no matching function for call to 'nth_element(std::vector<int>::iterator, __gnu_cxx::__normal_iterator<int*, std::vector<int> >)' nth_element(v.begin(),v.begin()+(poz-1)/2); ^ In file included from /usr/include/c++/6/algorithm:62:0, from main.cpp:9: /usr/include/c++/6/bits/stl_algo.h:4621:5: note: candidate: template<class _RAIter> void std::nth_element(_RAIter, _RAIter, _RAIter) nth_element(_RandomAccessIterator __first, _RandomAccessIterator __nth, ^~~~~~~~~~~ /usr/include/c++/6/bits/stl_algo.h:4621:5: note: template argument deduction/substitution failed: main.cpp:110:46: note: candidate expects 3 arguments, 2 provided nth_element(v.begin(),v.begin()+(poz-1)/2); ^ In file included from /usr/include/c++/6/algorithm:62:0, from main.cpp:9: /usr/include/c++/6/bits/stl_algo.h:4660:5: note: candidate: template<class _RAIter, class _Compare> void std::nth_element(_RAIter, _RAIter, _RAIter, _Compare) nth_element(_RandomAccessIterator __first, _RandomAccessIterator __nth, ^~~~~~~~~~~ /usr/include/c++/6/bits/stl_algo.h:4660:5: note: template argument deduction/substitution failed: main.cpp:110:46: note: candidate expects 4 arguments, 2 provided nth_element(v.begin(),v.begin()+(poz-1)/2); ^ main.cpp:112:1: warning: no return statement in function returning non-void [-Wreturn-type] } ^ Non zero exit status: 1

Ceva nu functioneaza?