Borderou de evaluare (job #2241732)
Utilizator | Data | 16 septembrie 2018 20:32:27 | |
---|---|---|---|
Problema | Principiul includerii si excluderii | Status | done |
Runda | Arhiva educationala | Compilator | cpp | Vezi sursa |
Scor | 0 |
Raport evaluator
Eroare de compilare:
user.cpp:11:27: error: ‘std::vector<long long int> div’ redeclared as different kind of symbol
std::vector < long long > div;
^~~
In file included from /usr/include/c++/6/cstdlib:75:0,
from /usr/include/c++/6/ext/string_conversions.h:41,
from /usr/include/c++/6/bits/basic_string.h:5417,
from /usr/include/c++/6/string:52,
from /usr/include/c++/6/bits/locale_classes.h:40,
from /usr/include/c++/6/bits/ios_base.h:41,
from /usr/include/c++/6/ios:42,
from /usr/include/c++/6/istream:38,
from /usr/include/c++/6/fstream:38,
from user.cpp:1:
/usr/include/stdlib.h:788:14: note: previous declaration ‘div_t div(int, int)’
extern div_t div (int __numer, int __denom)
^~~
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:27: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
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?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !