Record Detail

Compile Error

In file included from /in/driver/main.cpp:1:0:
/in/shortestP2P.hpp: In member function 'void ShortestP2P::readGraph()':
/in/shortestP2P.hpp:81:20: error: comparison between signed and unsigned integer expressions [-Werror=sign-compare]
     if (start_node >= num_of_nodes || end_node >= num_of_nodes || start_node < 0 || end_node < 0) {
         ~~~~~~~~~~~^~~~~~~~~~~~~~~
/in/shortestP2P.hpp:81:48: error: comparison between signed and unsigned integer expressions [-Werror=sign-compare]
     if (start_node >= num_of_nodes || end_node >= num_of_nodes || start_node < 0 || end_node < 0) {
                                       ~~~~~~~~~^~~~~~~~~~~~~~~
/in/shortestP2P.hpp:81:78: error: comparison of unsigned expression < 0 is always false [-Werror=type-limits]
     if (start_node >= num_of_nodes || end_node >= num_of_nodes || start_node < 0 || end_node < 0) {
                                                                   ~~~~~~~~~~~^~~
/in/shortestP2P.hpp:81:94: error: comparison of unsigned expression < 0 is always false [-Werror=type-limits]
     if (start_node >= num_of_nodes || end_node >= num_of_nodes || start_node < 0 || end_node < 0) {
                                                                                     ~~~~~~~~~^~~
cc1plus: all warnings being treated as errors

Information

Submit By
Type
Submission
Homework
Project 4
Language
C++
Submit At
2024-12-19 04:39:17
Judged At
2024-12-19 04:39:17
Judged By
Score
0
Total Time
0ms
Peak Memory
0 Bytes