Borderou de evaluare (job #1322712)
Utilizator | Data | 20 ianuarie 2015 12:17:16 | |
---|---|---|---|
Problema | Lupul Urias si Rau | Status | done |
Runda | Teme Pregatire ACM Unibuc 2014, Anul II | Compilator | cpp | Vezi sursa |
Scor | 0 |
Raport evaluator
Eroare de compilare:
user.cpp: In function ‘int main()’:
user.cpp:25:37: error: invalid user-defined conversion from ‘std::ifstream {aka std::basic_ifstream<char>}’ to ‘FILE* {aka _IO_FILE*}’ [-fpermissive]
fscanf(f,"%d %d",&auxd,&auxw);
^
In file included from /usr/include/c++/4.8/ios:44:0,
from /usr/include/c++/4.8/ostream:38,
from /usr/include/c++/4.8/iostream:39,
from user.cpp:1:
/usr/include/c++/4.8/bits/basic_ios.h:115:7: note: candidate is: std::basic_ios<_CharT, _Traits>::operator void*() const [with _CharT = char; _Traits = std::char_traits<char>] <near match>
operator void*() const
^
/usr/include/c++/4.8/bits/basic_ios.h:115:7: note: no known conversion for implicit ‘this’ parameter from ‘void*’ to ‘FILE* {aka _IO_FILE*}’
user.cpp:25:38: warning: ignoring return value of ‘int fscanf(FILE*, const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result]
fscanf(f,"%d %d",&auxd,&auxw);
^
Ceva nu functioneaza?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !