Borderou de evaluare (job #2069069)

Utilizator ApostolIlieDanielApostol Daniel ApostolIlieDaniel Data 18 noiembrie 2017 11:54:19
Problema Algoritmul lui Dijkstra Status done
Runda Arhiva educationala Compilator cpp | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: user.cpp: In function ‘void dijkstra(int)’: user.cpp:13:8: error: ‘i’ was not declared in this scope for (i = 1; i <= n; i++) { ^ user.cpp:14:5: error: ‘dist’ was not declared in this scope dist[i] = INF; ^ user.cpp:21:17: error: ‘dist’ was not declared in this scope if (cost <= dist[node]) { ^ user.cpp:22:12: error: ‘i’ was not declared in this scope for (i = 0; i <= G[node].size; i++) { ^ user.cpp: In function ‘int main()’: user.cpp:39:29: error: ‘m’ was not declared in this scope fscanf (fin, "%d%d", &n, &m); ^ user.cpp:40:8: error: ‘i’ was not declared in this scope for (i = 0; i < m; i++) { ^ user.cpp:41:29: error: ‘x’ was not declared in this scope fscanf (fin, "%d%d%d", &x, &y, &cost); ^ user.cpp:41:33: error: ‘y’ was not declared in this scope fscanf (fin, "%d%d%d", &x, &y, &cost); ^ user.cpp:41:37: error: ‘cost’ was not declared in this scope fscanf (fin, "%d%d%d", &x, &y, &cost); ^ user.cpp:43:3: error: expected ‘;’ before ‘}’ token } ^

Ceva nu functioneaza?