Interval Tree added

This commit is contained in:
IlyaShurupov 2024-02-13 00:18:52 +03:00 committed by Ilya Shurupov
parent 8955a02d05
commit 782a041ba8
6 changed files with 311 additions and 4 deletions

View file

@ -93,6 +93,7 @@ namespace tp {
// power
template <typename T>
[[nodiscard]] T pow(T x, uhalni n) {
if (n == 0) return 1;
T out = x;
for (uhalni i = 0; i < n - 1; i++) {
out = out * x;