Problem candles
User impotato
Submission Time 2023-11-30 22:29:40
Score 0
Max Time N/A
Max Memory N/A

Compile Error

candles.cpp: In function ‘int main()’:
candles.cpp:19:13: error: invalid conversion from ‘std::string*’ {aka ‘std::__cxx11::basic_string<char>*’} to ‘size_t’ {aka ‘long unsigned int’} [-fpermissive]
19 | qsort(x, x + n);
| ~~^~~
| |
| std::string* {aka std::__cxx11::basic_string<char>*}
candles.cpp:19:16: error: too few arguments to function ‘void qsort(void*, size_t, size_t, __compar_fn_t)’
19 | qsort(x, x + n);
| ^
In file included from /usr/include/c++/9/cstdlib:75,
from /usr/include/c++/9/ext/string_conversions.h:41,
from /usr/include/c++/9/bits/basic_string.h:6496,
from /usr/include/c++/9/string:55,
from /usr/include/c++/9/bits/locale_classes.h:40,
from /usr/include/c++/9/bits/ios_base.h:41,
from /usr/include/c++/9/ios:42,
fr