Record Detail

Compile Error

prepare (1/3): 
finished

make (2/3): 
g++ -c main.cpp 
main.cpp:209:5: error: expected initializer before 'if'
     if(graph.empty()){cout<<"The total weight of MST is " << 0<<endl;return;}
     ^~
main.cpp:211:5: error: 'graph' does not name a type; did you mean 'isgraph'?
     graph[0]->visited = true; T.push_back(graph[0]);
     ^~~~~
     isgraph
main.cpp:211:31: error: 'T' does not name a type
     graph[0]->visited = true; T.push_back(graph[0]);
                               ^
main.cpp:212:5: error: expected unqualified-id before 'while'
     while (true) {
     ^~~~~
main.cpp:232:9: error: 'cout' does not name a type
         cout<<"No MST exists!"<<endl;
         ^~~~
main.cpp:233:1: error: expected declaration before '}' token
 }
 ^
Makefile:5: recipe for target 'main.o' failed
make: *** [main.o] Error 1

build failed

Information

Submit By
Type
Submission
Homework
Project Five: Graph Algorithms
Language
GNU Make
Submit At
2018-12-07 10:52:45
Judged At
2018-12-07 10:52:45
Judged By
Score
0
Total Time
0ms
Peak Memory
0 Bytes