password.cpp: In function 'void MERGE(std::string&, std::string&)':
password.cpp:18:23: warning: comparison of integer expressions of different signedness: 'int' and 'std::__cxx11::basic_string<char>::size_type' {aka 'long unsigned int'} [-Wsign-compare]
18 | for (int j = 0; j < b.length(); j++)
| ~~^~~~~~~~~~~~
password.cpp:21:11: error: 'std::string' {aka 'class std::__cxx11::basic_string<char>'} has no member named 'ins'
21 | b.ins(b.begin() + j, a[i]);
| ^~~
password.cpp:21:32: error: 'i' was not declared in this scope
21 | b.ins(b.begin() + j, a[i]);
| ^
password.cpp: In function 'std::string guess(int, int)':
password.cpp:33:13: error: 'std::string' {aka 'class std::__cxx11::basic_string<char>'} has no member named 'pb'
33 | tmp.pb('a');
| ^~
password.cpp:39:24: error: 'temp' was not declared in this scope; did you mean 'tmp'?
39 | cnt[i] = query(temp);
| ^~~~
| tmp
password.cpp:47:29: error: 'const value_type' {aka 'const struct std::pair<int, std::__cxx11::basic_string<char> >'} has no member named 'se'
47 | string a = pq.top().se;
| ^~
password.cpp:49:29: error: 'const value_type' {aka 'const struct std::pair<int, std::__cxx11::basic_string<char> >'} has no member named 'se'
49 | string b = pq.top().se;
| ^~
password.cpp:54:17: error: 'mpr' was not declared in this scope
54 | pq.push(mpr(b.length(), b));
| ^~~
password.cpp:57:18: error: could not convert 'pq.std::priority_queue<std::pair<int, std::__cxx11::basic_string<char> >, std::vector<std::pair<int, std::__cxx11::basic_string<char> > >, std::greater<std::pair<int, std::__cxx11::basic_string<char> > > >::top()' from 'const value_type' {aka 'const std::pair<int, std::__cxx11::basic_string<char> >'} to 'std::string' {aka 'std::__cxx11::basic_string<char>'}
57 | return pq.top();
| ~~~~~~^~
| |
| const value_type {aka const std::pair<int, std::__cxx11::basic_string<char> >}
password.cpp:35:9: warning: unused variable 'prev' [-Wunused-variable]
35 | int prev = 0;
| ^~~~