fix: add <cstdint> to treap.cpp

This commit is contained in:
realstealthninja
2024-08-31 11:18:06 +05:30
parent 82cb276f44
commit 5421cfcdeb

View File

@@ -19,6 +19,7 @@
#include <array> /// For array
#include <cassert> /// For assert
#include <cstdint> /// for integral typedefs
#include <iostream> /// For IO operations
/**
@@ -157,11 +158,9 @@ struct Treap {
}
if (k == key[x]) {
return size[childs[x][0]] + 1;
}
else if (k < key[x]) {
} else if (k < key[x]) {
return _get_rank(childs[x][0], k);
}
else {
} else {
return size[childs[x][0]] + cnt[x] + _get_rank(childs[x][1], k);
}
}