diff options
| author | mzuenni <michi.zuendorf@gmail.com> | 2023-01-10 11:40:09 +0100 |
|---|---|---|
| committer | mzuenni <michi.zuendorf@gmail.com> | 2023-01-10 11:40:09 +0100 |
| commit | fd1f2b36e95c03625297b7b8cba3b1a04a0cc0ed (patch) | |
| tree | b143619750b90fbfa45a98be9ea56904d1a7129d /datastructures/treap.cpp | |
| parent | 8faa84ca282d51e9ce4fef535e68325adabcebad (diff) | |
change whitespaces
Diffstat (limited to 'datastructures/treap.cpp')
| -rw-r--r-- | datastructures/treap.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/datastructures/treap.cpp b/datastructures/treap.cpp index 6296392..eef56b4 100644 --- a/datastructures/treap.cpp +++ b/datastructures/treap.cpp @@ -1,7 +1,7 @@ struct node { int key, prio, left, right, size; node(int key, int prio) : key(key), prio(prio), left(-1), - right(-1), size(1) {}; + right(-1), size(1) {}; }; vector<node> treap; @@ -13,7 +13,7 @@ int getSize(int root) { void update(int root) { if (root < 0) return; treap[root].size = 1 + getSize(treap[root].left) - + getSize(treap[root].right); + + getSize(treap[root].right); } pair<int, int> split(int root, int minKeyRight) { |
