Borderou de evaluare (job #2241730)

Utilizator ContDeRacistAliniateEBlat ContDeRacist Data 16 septembrie 2018 20:31:56
Problema Principiul includerii si excluderii Status done
Runda Arhiva educationala Compilator cpp | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: user.cpp:9:1: error: ‘vector’ does not name a type vector < int > prime; ^~~~~~ user.cpp:11:1: error: ‘vector’ does not name a type vector < long long > div; ^~~~~~ user.cpp: In function ‘void precalc_p()’: user.cpp:16:5: error: ‘prime’ was not declared in this scope prime.push_back(1); ^~~~~ user.cpp: In function ‘void peenex(int, long long int, int)’: user.cpp:29:20: error: request for member ‘size’ in ‘div’, which is of non-class type ‘div_t(int, int) throw ()’ if (poz == div.size()) { ^~~~ user.cpp:34:27: warning: pointer to a function used in arithmetic [-Wpointer-arith] if (num <= a / div[poz]) ^ user.cpp:34:18: error: invalid operands of types ‘long long int’ and ‘div_t(int, int) throw ()’ to binary ‘operator/’ if (num <= a / div[poz]) ~~^~~~~~~~~~ user.cpp:35:38: warning: pointer to a function used in arithmetic [-Wpointer-arith] peenex(poz + 1, num * div[poz], - k); ^ user.cpp:35:29: error: invalid operands of types ‘long long int’ and ‘div_t(int, int) throw ()’ to binary ‘operator*’ peenex(poz + 1, num * div[poz], - k); ~~~~^~~~~~~~~~ user.cpp: In function ‘int main()’: user.cpp:46:13: error: request for member ‘clear’ in ‘div’, which is of non-class type ‘div_t(int, int) throw ()’ div.clear(); ^~~~~ user.cpp:48:29: error: ‘prime’ was not declared in this scope for (int i = 1; i < prime.size(); ++i) ^~~~~ user.cpp:50:21: error: request for member ‘push_back’ in ‘div’, which is of non-class type ‘div_t(int, int) throw ()’ div.push_back(prime[i]); ^~~~~~~~~ user.cpp:55:17: error: request for member ‘push_back’ in ‘div’, which is of non-class type ‘div_t(int, int) throw ()’ div.push_back(b); ^~~~~~~~~

Ceva nu functioneaza?