summaryrefslogtreecommitdiff
path: root/string/lyndon.cpp
diff options
context:
space:
mode:
authorMZuenni <michi.zuendorf@gmail.com>2023-03-01 11:36:26 +0100
committerMZuenni <michi.zuendorf@gmail.com>2023-03-01 11:36:26 +0100
commit12afe719ce268bb10aa93a910079a44eb08999b8 (patch)
tree0937a117287eebe3942e0506d27143eff4980d09 /string/lyndon.cpp
parentad8456f7c5d44d3c647b3a368050a5d2f39ae3c3 (diff)
removed trailing whitespaces and use more structured bindings
Diffstat (limited to 'string/lyndon.cpp')
-rw-r--r--string/lyndon.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/string/lyndon.cpp b/string/lyndon.cpp
index 6a131a5..858c3db 100644
--- a/string/lyndon.cpp
+++ b/string/lyndon.cpp
@@ -1,5 +1,5 @@
bool next(string& s, int n, char mi = '0', char ma = '1') {
- for (ll i = sz(s), j = sz(s); i < n; i++)
+ for (int i = sz(s), j = sz(s); i < n; i++)
s.push_back(s[i % j]);
while(!s.empty() && s.back() == ma) s.pop_back();
if (s.empty()) {