Skip to content

Instantly share code, notes, and snippets.

@Vicfred
Created August 1, 2022 03:12
Show Gist options
  • Save Vicfred/9a6be444d36cdf991d5eb85cad8baaeb to your computer and use it in GitHub Desktop.
Save Vicfred/9a6be444d36cdf991d5eb85cad8baaeb to your computer and use it in GitHub Desktop.
allstrings.cpp
set<string> valid{"a", "b", "c", "?"};
for(const auto& i : valid) {
for(const auto& j : valid) {
for(const auto& k : valid) {
for(const auto& l : valid) {
for(const auto& m : valid) {
for(const auto& n : valid) {
for(const auto& o : valid) {
string str = i + j + k + l + m + n + o;
good.insert(str);
}
}
}
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment