Problem | moneychanger |
---|---|
User | PlayVoltz |
Submission Time | 2023-05-18 08:38:54 |
Score | 0 |
Max Time | N/A |
Max Memory | N/A |
Owl Get a Life
moneychanger.cpp: In function ‘int main()’:
moneychanger.cpp:10:9: error: request for member ‘push_back’ in ‘money’, which is of non-class type ‘int’
10 | money.push_back(coin);
| ^~~~~~~~~
moneychanger.cpp:13:13: error: ‘begin’ was not declared in this scope
13 | for (int i:money){
| ^~~~~
moneychanger.cpp:13:13: note: suggested alternatives:
In file included from /usr/include/x86_64-linux-gnu/c++/9/bits/stdc++.h:95,
from moneychanger.cpp:1:
/usr/include/c++/9/valarray:1224:5: note: ‘std::begin’
1224 | begin(const valarray<_Tp>& __va)
| ^~~~~
In file included from /usr/include/c++/9/filesystem:38,
from /usr/include/x86_64-linux-gnu/c++/9/bits/stdc++.h:129,
from moneychanger.cpp:1:
/usr/include/c++/9/bits/fs_dir.h:516:3: note: ‘std::filesystem::__cxx11::begin’
516 | begin(recursive_directory_iterator __iter) noexcept