Borderou de evaluare (job #1844633)
Utilizator | Data | 10 ianuarie 2017 10:47:26 | |
---|---|---|---|
Problema | Evaluarea unei expresii | Status | done |
Runda | Arhiva educationala | Compilator | cpp | Vezi sursa |
Scor | 0 |
Raport evaluator
Eroare de compilare:
user.cpp: In function ‘void eval()’:
user.cpp:12:17: error: void value not ignored as it ought to be
ll r=termen();
^
user.cpp:18:14: error: invalid operands of types ‘ll {aka long long int}’ and ‘void’ to binary ‘operator+’
r+=termen();
^
user.cpp:18:14: error: in evaluation of ‘operator+=(ll {aka long long int}, void)’
user.cpp:23:14: error: invalid operands of types ‘ll {aka long long int}’ and ‘void’ to binary ‘operator-’
r-=termen();
^
user.cpp:23:14: error: in evaluation of ‘operator-=(ll {aka long long int}, void)’
user.cpp:26:12: error: return-statement with a value, in function returning 'void' [-fpermissive]
return r;
^
user.cpp: In function ‘void termen()’:
user.cpp:30:17: error: void value not ignored as it ought to be
ll r=factor();
^
user.cpp:36:14: error: invalid operands of types ‘ll {aka long long int}’ and ‘void’ to binary ‘operator*’
r*=factor();
^
user.cpp:36:14: error: in evaluation of ‘operator*=(ll {aka long long int}, void)’
user.cpp:41:14: error: invalid operands of types ‘int*’ and ‘void’ to binary ‘operator/’
p/=factor();
^
user.cpp:41:14: error: in evaluation of ‘operator/=(int*, void)’
user.cpp:44:12: error: return-statement with a value, in function returning 'void' [-fpermissive]
return r;
^
user.cpp: In function ‘void factor()’:
user.cpp:53:10: error: void value not ignored as it ought to be
r=eval();
^
user.cpp:64:12: error: return-statement with a value, in function returning 'void' [-fpermissive]
return r;
^
user.cpp: In function ‘int main()’:
user.cpp:69:8: error: cannot bind ‘std::basic_istream<char>’ lvalue to ‘std::basic_istream<char>&&’
f>>s;
^
In file included from /usr/include/c++/4.8/fstream:38:0,
from user.cpp:1:
/usr/include/c++/4.8/istream:872:5: error: initializing argument 1 of ‘std::basic_istream<_CharT, _Traits>& std::operator>>(std::basic_istream<_CharT, _Traits>&&, _Tp&) [with _CharT = char; _Traits = std::char_traits<char>; _Tp = int [100004]]’
operator>>(basic_istream<_CharT, _Traits>&& __is, _Tp& __x)
^
user.cpp:71:6: error: no match for ‘operator<<’ (operand types are ‘std::ofstream {aka std::basic_ofstream<char>}’ and ‘void’)
g<<eval();
^
user.cpp:71:6: note: candidates are:
Ceva nu functioneaza?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !