prog.cpp: In function 'void BFS(int, int)':
prog.cpp:27:8: error: no match for 'operator!' (operand type is 'std::queue<int>')
while(!Q,empty()) {
^
prog.cpp:27:8: note: candidate is:
prog.cpp:27:8: note: operator!(bool) <built-in>
prog.cpp:27:8: note: no known conversion for argument 1 from 'std::queue<int>' to 'bool'
prog.cpp:27:17: error: 'empty' was not declared in this scope
while(!Q,empty()) {
^
prog.cpp:31:14: error: expected primary-expression before '<<' token
cout << u, << " ";
^
prog.cpp:35:32: error: expected ';' before '{' token
for(int v = 1; v <= N; v++)v {
^
prog.cpp:81:1: error: expected '}' at end of input
}
^
prog.cpp:81:1: error: expected '}' at end of input