Borderou de evaluare (job #1909735)

Utilizator sebastianlazarLazar Constantin Sebastian sebastianlazar Data 7 martie 2017 13:45:54
Problema Algoritmul Bellman-Ford Status done
Runda Arhiva educationala Compilator cpp | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: user.cpp: In function ‘void citire()’: user.cpp:19:9: warning: unused variable ‘i’ [-Wunused-variable] int i,a,b; ^ user.cpp:19:13: warning: unused variable ‘b’ [-Wunused-variable] int i,a,b; ^ user.cpp: In function ‘void afisare()’: user.cpp:30:26: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] for(i=0;i<=G[1].size();i++) ^ user.cpp:32:21: error: cannot bind ‘std::basic_ostream<char>’ lvalue to ‘std::basic_ostream<char>&&’ fout<<G[1][i]; ^ 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:602:5: error: initializing argument 1 of ‘std::basic_ostream<_CharT, _Traits>& std::operator<<(std::basic_ostream<_CharT, _Traits>&&, const _Tp&) [with _CharT = char; _Traits = std::char_traits<char>; _Tp = varf]’ operator<<(basic_ostream<_CharT, _Traits>&& __os, const _Tp& __x) ^ user.cpp: In function ‘int main()’: user.cpp:37:9: error: ‘i’ was not declared in this scope for(i=1;i<=n;i++) ^ user.cpp:39:17: error: ‘INFINIT’ was not declared in this scope cmin[i]=INFINIT; ^ user.cpp:44:5: error: ‘C’ was not declared in this scope C.push(p); ^ user.cpp:47:9: error: ‘x’ was not declared in this scope x=C.front();C.pop(); ^ user.cpp:48:13: error: ‘i’ was not declared in this scope for(i=0;i<G[x].size();i++) ^ user.cpp:50:23: error: ‘vf’ was not declared in this scope if(cmin[G[vf][i].x]>cmin[vf]+G[vf][i].c) ^ user.cpp:55:36: error: expected ‘]’ before ‘)’ token if(nr[G[vf][i].x>=n) ^

Ceva nu functioneaza?