Record Detail

Compile Error

/in/p3.cpp: In function 'int main(int, char**)':
/in/p3.cpp:76:19: error: comparison between signed and unsigned integer expressions [-Werror=sign-compare]
     for (int i=0;i<MAXCREATURES;i++){
                  ~^~~~~~~~~~~~~
/in/p3.cpp:66:19: error: unused variable 'instructionTempArray' [-Werror=unused-variable]
     instruction_t instructionTempArray[MAXPROGRAM]={instructionTemp};
                   ^~~~~~~~~~~~~~~~~~~~
/in/p3.cpp: In function 'void readFile(std::__cxx11::string, std::__cxx11::string*)':
/in/p3.cpp:154:9: error: variable 'spaceLocation' set but not used [-Werror=unused-but-set-variable]
     int spaceLocation=countLines(filename);
         ^~~~~~~~~~~~~
cc1plus: all warnings being treated as errors
/in/simulation.cpp: In function 'void creature_initial(creature_t* (*)[20], creature_t*)':
/in/simulation.cpp:88:19: error: comparison between signed and unsigned integer expressions [-Werror=sign-compare]
     for (int i=0;i<MAXCREATURES; i++){
                  ~^~~~~~~~~~~~~
cc1plus: all warnings being treated as errors

Information

Submit By
Type
Submission
Homework
Project 3
Language
C++
Submit At
2022-11-06 23:55:58
Judged At
2022-11-10 07:19:21
Judged By
Score
0
Total Time
0ms
Peak Memory
0 Bytes