Borderou de evaluare (job #3164629)

Utilizator nicholas9onicaOnica Nicholas Andrei nicholas9onica Data 3 noiembrie 2023 22:31:55
Problema Hashuri Status done
Runda Arhiva educationala Compilator cpp-64 | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: main.cpp: In function 'int get_nr_cif(int)': main.cpp:13:14: error: expected ';' before 'x' 13 | cnt++ | ^ | ; 14 | x=x/10; | ~ main.cpp: At global scope: main.cpp:18:18: error: 'x' was not declared in this scope 18 | long long putere(x,put) | ^ main.cpp:18:20: error: 'put' was not declared in this scope; did you mean 'putw'? 18 | long long putere(x,put) | ^~~ | putw main.cpp:18:23: error: expression list treated as compound expression in initializer [-fpermissive] 18 | long long putere(x,put) | ^ main.cpp: In function 'long long int hashumeu(long long int)': main.cpp:37:24: error: 'putere' cannot be used as a function 37 | val_cod+=putere(b,nr_cif)*x%10; | ~~~~~~^~~~~~~~~~ main.cpp: In function 'int main()': main.cpp:45:5: error: 'lon' was not declared in this scope; did you mean 'long'? 45 | lon long val_hash; | ^~~ | long main.cpp:53:9: error: 'val_hash' was not declared in this scope 53 | val_hash=hashumeu(x); | ^~~~~~~~ main.cpp:57:47: error: no matching function for call to 'find(std::vector<std::vector<int> >&)' 57 | std::vector<int>::iterator it=find(H) | ~~~~^~~ In file included from /usr/include/c++/12.2.1/bits/locale_facets.h:48, from /usr/include/c++/12.2.1/bits/basic_ios.h:37, from /usr/include/c++/12.2.1/ios:44, from /usr/include/c++/12.2.1/ostream:38, from /usr/include/c++/12.2.1/iostream:39, from main.cpp:1: /usr/include/c++/12.2.1/bits/streambuf_iterator.h:434:5: note: candidate: 'template<class _CharT2> typename __gnu_cxx::__enable_if<std::__is_char<_CharT2>::__value, std::istreambuf_iterator<_CharT> >::__type std::find(istreambuf_iterator<_CharT>, istreambuf_iterator<_CharT>, const _CharT2&)' 434 | find(istreambuf_iterator<_CharT> __first, | ^~~~ /usr/include/c++/12.2.1/bits/streambuf_iterator.h:434:5: note: template argument deduction/substitution failed: main.cpp:57:47: note: 'std::vector<std::vector<int> >' is not derived from 'std::istreambuf_iterator<_CharT>' 57 | std::vector<int>::iterator it=find(H) | ~~~~^~~ main.cpp:57:40: warning: unused variable 'it' [-Wunused-variable] 57 | std::vector<int>::iterator it=find(H) | ^~ Non zero exit status: 1

Ceva nu functioneaza?