Borderou de evaluare (job #2190355)

Utilizator MihaiAntonMihai Anton MihaiAnton Data 30 martie 2018 17:00:14
Problema BFS - Parcurgere in latime Status done
Runda Arhiva educationala Compilator cpp | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: user.cpp: In function ‘VERTEX* vertexCreate(int)’: user.cpp:59:24: error: ‘INT_MAX’ was not declared in this scope newVertex->distance = INT_MAX; //set the attributes ^~~~~~~ user.cpp: In function ‘int graphDestroy(GRAPH*)’: user.cpp:213:7: warning: unused variable ‘adjListDestroyStatus’ [-Wunused-variable] int adjListDestroyStatus = adjListDestroy(graph->adjList[i]); //destroy the adjacency list ^~~~~~~~~~~~~~~~~~~~ user.cpp: In function ‘int graphReadFromFileWWeight(GRAPH*, char*, int, int)’: user.cpp:273:32: error: ‘fopen_s’ was not declared in this scope fopen_s(&inFile, fileName, "r"); ^ user.cpp:279:47: error: ‘fscanf_s’ was not declared in this scope fscanf_s(inFile, "%d %d %d", &aux, &aux, &aux); ^ user.cpp: In function ‘int graphReadFromFileWoWeight(GRAPH*, char*, int, int)’: user.cpp:318:32: error: ‘fopen_s’ was not declared in this scope fopen_s(&inFile, fileName, "r"); ^ user.cpp:324:47: error: ‘fscanf_s’ was not declared in this scope fscanf_s(inFile, "%d %d %d", &aux, &aux, &aux); ^ user.cpp: In function ‘int** graphGetAdjMatrix(GRAPH*)’: user.cpp:402:22: error: ‘INT_MAX’ was not declared in this scope adjMatrix[i][j] = INT_MAX; ^~~~~~~ user.cpp: In function ‘void BFS(GRAPH*, VERTEX*, FILE*)’: user.cpp:550:19: error: ‘INT_MAX’ was not declared in this scope if (distance == INT_MAX) ^~~~~~~ user.cpp: In function ‘int main()’: user.cpp:573:32: error: ‘fopen_s’ was not declared in this scope fopen_s(&inFile, "bfs.in", "r"); ^ user.cpp:574:68: error: ‘fscanf_s’ was not declared in this scope fscanf_s(inFile, "%d %d %d", &vertexCount, &edgeCount, &sourceNode); //reads the data ^ user.cpp:579:77: warning: ISO C++ forbids converting a string constant to ‘char*’ [-Wwrite-strings] graphReadFromFile(graph, "bfs.in", vertexCount, edgeCount, UNPONDERED_GRAPH); //reads the data from file ^ user.cpp: In function ‘int graphReadFromFile(GRAPH*, char*, int, int, int)’: user.cpp:360:1: warning: control reaches end of non-void function [-Wreturn-type] } ^

Ceva nu functioneaza?