Borderou de evaluare (job #1791493)
Utilizator | Cojocaru Andrei Cristian Cojocaru_Andrei_Cristian | Data | 29 octombrie 2016 13:59:55 |
---|---|---|---|
Problema | Suma si numarul divizorilor | Status | done |
Runda | Arhiva educationala | Compilator | cpp | Vezi sursa |
Scor | 0 |
Raport evaluator
Eroare de compilare:
user.cpp:4:13: error: ‘long long int div’ redeclared as different kind of symbol
long long div=1,sum=1,pos=1;
^
In file included from /usr/include/c++/4.8/cstdlib:72:0,
from /usr/include/c++/4.8/ext/string_conversions.h:41,
from /usr/include/c++/4.8/bits/basic_string.h:2815,
from /usr/include/c++/4.8/string:52,
from /usr/include/c++/4.8/bits/locale_classes.h:40,
from /usr/include/c++/4.8/bits/ios_base.h:41,
from /usr/include/c++/4.8/ios:42,
from /usr/include/c++/4.8/istream:38,
from /usr/include/c++/4.8/fstream:38,
from user.cpp:1:
/usr/include/stdlib.h:785:14: error: previous declaration of ‘div_t div(int, int)’
extern div_t div (int __numer, int __denom)
^
user.cpp: In function ‘void tr(int)’:
user.cpp:44:8: error: overloaded function with no contextual type information
div=1;
^
user.cpp:54:12: error: overloaded function with no contextual type information
div*=(put+1);
^
user.cpp:55:12: error: overloaded function with no contextual type information
div%=9973;
^
user.cpp:64:12: error: overloaded function with no contextual type information
div*=2;
^
user.cpp:43:9: warning: unused variable ‘poz’ [-Wunused-variable]
int poz=0,put=0;
^
user.cpp: In function ‘int main()’:
user.cpp:80:14: error: no match for ‘operator<<’ (operand types are ‘std::ofstream {aka std::basic_ofstream<char>}’ and ‘<unresolved overloaded function type>’)
cout << div << " " << sum << endl;
^
user.cpp:80:14: note: candidates are:
In file included from /usr/include/c++/4.8/istream:39:0,
from /usr/include/c++/4.8/fstream:38,
from user.cpp:1:
/usr/include/c++/4.8/ostream:108:7: note: std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(std::basic_ostream<_CharT, _Traits>::__ostream_type& (*)(std::basic_ostream<_CharT, _Traits>::__ostream_type&)) [with _CharT = char; _Traits = std::char_traits<char>; std::basic_ostream<_CharT, _Traits>::__ostream_type = std::basic_ostream<char>]
operator<<(__ostream_type& (*__pf)(__ostream_type&))
^
/usr/include/c++/4.8/ostream:108:7: note: no known conversion for argument 1 from ‘<unresolved overloaded function type>’ to ‘std::basic_ostream<char>::__ostream_type& (*)(std::basic_ostream<char>::__ostream_type&) {aka std::basic_ostream<char>& (*)(std::basic_ostream<char>&)}’
/usr/include/c++/4.8/ostream:117:7: note: std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(std::basic_ostream<_CharT, _Traits>::__ios_type& (*)(std::basic_ostream<_CharT, _Traits>::__ios_type&)) [with _CharT = char; _Traits = std::char_traits<char>; std::basic_ostream<_CharT, _Traits>::__ostream_type = std::basic_ostream<char>; std::basic_ostream<_CharT, _Traits>::__ios_type = std::basic_ios<char>]
operator<<(__ios_type& (*__pf)(__ios_type&))
^
/usr/include/c++/4.8/ostream:117:7: note: no known conversion for argument 1 from ‘<unresolved overloaded function type>’ to ‘std::basic_ostream<char>::__ios_type& (*)(std::basic_ostream<char>::__ios_type&) {aka std::basic_ios<char>& (*)(std::basic_ios<char>&)}’
/usr/include/c++/4.8/ostream:127:7: note: std::basic_ostream<_CharT, _Traits>::__ostream_type& std::basic_ostream<_CharT, _Traits>::operator<<(std::ios_base& (*)(std::ios_base&)) [with _CharT = char; _Traits = std::char_traits<char>; std::basic_ostream<_CharT, _Traits>::__ostream_type = std::basic_ostream<char>]
operator<<(ios_base& (*__pf) (ios_base&))
Ceva nu functioneaza?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !