Refactor benchmark to use randomized vectors instead of sets

- Replaced std::set with std::vector for sequence handling.
- Added randomization of sequences to avoid ordered input bias.
- Removed unused balance function and related code in bst.cpp and bst.h.
- Fixed bugs in list insertion and search logic.
- Updated plot.py to allow custom y-axis labels and enable log scale for build plots.
This commit is contained in:
2025-05-14 19:42:14 +02:00
parent aae0ce7241
commit 899c844c78
5 changed files with 36 additions and 59 deletions
-3
View File
@@ -8,8 +8,5 @@ struct Tree {
Tree *insert(Tree *root, int value);
Tree *search(Tree *root, int value);
void traverseInOrder(Tree *root,std::vector<int> &vec);
Tree *rebuild(std::vector<int> *vec, int start, int end);
Tree *balance(Tree *root);
void deleteTree(Tree *root);
int getHeight(Tree *root, int height);