Borderou de evaluare (job #1085985)

Utilizator laurionLaurentiu Ion laurion Data 17 ianuarie 2014 17:03:02
Problema Substr Status done
Runda Arhiva de probleme Compilator cpp | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: user.cpp: In function ‘int nr_aparitii(int)’: user.cpp:54:38: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] for(int i = len; i < text.length(); i ++){ ^ user.cpp:63:47: error: ‘typeof’ has not been declared return max_element(H.begin(), H.end(), [](typeof *H.begin() a, typeof *H.begin() b){ ^ user.cpp:63:56: error: expected ‘,’ or ‘...’ before ‘.’ token return max_element(H.begin(), H.end(), [](typeof *H.begin() a, typeof *H.begin() b){ ^ user.cpp: In lambda function: user.cpp:64:16: error: ‘a’ was not declared in this scope return a.second < b.second; ^ user.cpp:64:27: error: ‘b’ was not declared in this scope return a.second < b.second; ^ In file included from /usr/local/include/c++/4.8.0/algorithm:62:0, from user.cpp:13: /usr/local/include/c++/4.8.0/bits/stl_algo.h: In instantiation of ‘_FIter std::max_element(_FIter, _FIter, _Compare) [with _FIter = std::tr1::__detail::_Hashtable_iterator<std::pair<const int, int>, false, false>; _Compare = nr_aparitii(int)::__lambda0]’: user.cpp:65:6: required from here /usr/local/include/c++/4.8.0/bits/stl_algo.h:6339:32: error: no match for call to ‘(nr_aparitii(int)::__lambda0) (std::pair<const int, int>&, std::pair<const int, int>&)’ if (__comp(*__result, *__first)) ^ user.cpp:63:45: note: candidates are: return max_element(H.begin(), H.end(), [](typeof *H.begin() a, typeof *H.begin() b){ ^ In file included from /usr/local/include/c++/4.8.0/algorithm:62:0, from user.cpp:13: /usr/local/include/c++/4.8.0/bits/stl_algo.h:6339:32: note: void (*)(int*) <conversion> if (__comp(*__result, *__first)) ^ /usr/local/include/c++/4.8.0/bits/stl_algo.h:6339:32: note: candidate expects 2 arguments, 3 provided user.cpp:63:87: note: nr_aparitii(int)::__lambda0 return max_element(H.begin(), H.end(), [](typeof *H.begin() a, typeof *H.begin() b){ ^ user.cpp:63:87: note: candidate expects 1 argument, 2 provided

Ceva nu functioneaza?