We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent abe1aa5 commit dca9687Copy full SHA for dca9687
C++/synonymous-sentences.cpp
@@ -45,7 +45,7 @@ class Solution {
45
(*inv_lookup)[(*lookup)[x]] = x;
46
}
47
48
- vector<string> split(const string& s, const char delim) {
+ vector<string> split(const string& s, const char delim) const {
49
vector<string> tokens;
50
stringstream ss(s);
51
string token;
@@ -57,7 +57,7 @@ class Solution {
57
return tokens;
58
59
60
- vector<string> product(const vector<vector<string>>& options) {
+ vector<string> product(const vector<vector<string>>& options) const {
61
vector<string> result;
62
int total = 1;
63
for (const auto& opt : options) {
0 commit comments