Borderou de evaluare (job #2949113)
Utilizator | Data | 29 noiembrie 2022 20:29:27 | |
---|---|---|---|
Problema | Suma4 | Status | done |
Runda | Arhiva de probleme | Compilator | cpp-64 | Vezi sursa |
Scor | 0 |
Raport evaluator
Eroare de compilare:
main.cpp: In member function 'void MinAndPath::print()':
main.cpp:51:31: warning: comparison of integer expressions of different signedness: 'int' and 'std::vector<int>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
51 | for (int i = 1; i < path.size(); ++i) {
| ~~^~~~~~~~~~~~~
main.cpp: At global scope:
main.cpp:92:50: error: 'cell' has incomplete type
92 | void addNextCell(reference_wrapper<Cell> cell) {
| ~~~~~~~~~~~~~~~~~~~~~~~~^~~~
In file included from /usr/include/c++/10/bits/move.h:57,
from /usr/include/c++/10/bits/nested_exception.h:40,
from /usr/include/c++/10/exception:148,
from /usr/include/c++/10/ios:39,
from /usr/include/c++/10/istream:38,
from /usr/include/c++/10/fstream:38,
from main.cpp:1:
/usr/include/c++/10/type_traits:2160:11: note: declaration of 'class std::reference_wrapper<Cell>'
2160 | class reference_wrapper;
| ^~~~~~~~~~~~~~~~~
main.cpp: In member function 'std::string Cell::toString()':
main.cpp:99:30: error: conversion from 'std::reference_wrapper<Cell>' to non-scalar type 'Cell' requested
99 | for (Cell cell : nextCells) {
| ^~~~~~~~~
main.cpp: In function 'MinAndPath computeMinimumSum(Cell&)':
main.cpp:218:38: error: conversion from '__gnu_cxx::__alloc_traits<std::allocator<std::reference_wrapper<Cell> >, std::reference_wrapper<Cell> >::value_type' {aka 'std::reference_wrapper<Cell>'} to non-scalar type 'Cell' requested
218 | Cell firstCell = nextCells.at(0);
| ~~~~~~~~~~~~^~~
main.cpp:222:29: error: conversion from 'std::reference_wrapper<Cell>' to non-scalar type 'Cell' requested
222 | for (Cell oneCell : nextCells) {
| ^~~~~~~~~
main.cpp: In function 'Cell* linkCells(Level*)':
main.cpp:262:42: error: cannot convert 'Cell' to 'std::reference_wrapper<Cell>'
262 | aCell -> addNextCell(*under);
| ^~~~~~
| |
| Cell
main.cpp:92:50: note: initializing argument 1 of 'void Cell::addNextCell(std::reference_wrapper<Cell>)'
92 | void addNextCell(reference_wrapper<Cell> cell) {
| ~~~~~~~~~~~~~~~~~~~~~~~~^~~~
main.cpp:263:42: error: cannot convert 'Cell' to 'std::reference_wrapper<Cell>'
263 | aCell -> addNextCell(*east);
| ^~~~~
| |
| Cell
main.cpp:92:50: note: initializing argument 1 of 'void Cell::addNextCell(std::reference_wrapper<Cell>)'
92 | void addNextCell(reference_wrapper<Cell> cell) {
| ~~~~~~~~~~~~~~~~~~~~~~~~^~~~
main.cpp:264:42: error: cannot convert 'Cell' to 'std::reference_wrapper<Cell>'
264 | aCell -> addNextCell(*south);
| ^~~~~~
| |
Non zero exit status: 1
Ceva nu functioneaza?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !