Problem lunchbox
User Henries
Submission Time 2024-06-14 21:33:02
Score 0
Max Time N/A
Max Memory N/A

Compile Error

lunchbox.cpp: In function ‘int main()’:
lunchbox.cpp:7:22: error: expected ‘;’ before ‘)’ token
7 | for (int i=0;i<m<i++){
| ^
| ;
lunchbox.cpp:10:15: error: no match for ‘operator=’ (operand types are ‘std::__cxx11::list<int>’ and ‘int’)
10 | mylist[i] = a;
| ^
In file included from /usr/include/c++/9/list:64,
from /usr/include/x86_64-linux-gnu/c++/9/bits/stdc++.h:79,
from lunchbox.cpp:1:
/usr/include/c++/9/bits/list.tcc:267:5: note: candidate: ‘std::__cxx11::list<_Tp, _Alloc>& std::__cxx11::list<_Tp, _Alloc>::operator=(const std::__cxx11::list<_Tp, _Alloc>&) [with _Tp = int; _Alloc = std::allocator<int>]’
267 | list<_Tp, _Alloc>::
| ^~~~~~~~~~~~~~~~~
/usr/include/c++/9/bits/list.tcc:268:27: note: no known conversion for argument 1 from ‘int’ to ‘const std::__cxx11::li