diff --git a/treap.hpp b/treap.hpp index 63f0c93..425c4ac 100644 --- a/treap.hpp +++ b/treap.hpp @@ -110,6 +110,9 @@ public: two.first = join(two.first, l); root = join(two); } + void append(string s) { + insert(size(), s); + } // Line removal void remove(count_type k) { auto two = split(root, k+1);