I've implemented an AVL tree on C++ and would like to stress test it. To do that I need some other implementation of Avl tree to compare the results. As an acceptance criterion, I'm going to use preorder and postorder traversals if they are matching appropriately with my results it will mean that the algorithms are working correctly. But the problem is that I couldn't found any C++ library containing an implementation of AVL tree that provides a preorder and postorder traversal functionality. How else is it possible to stress test it?

1 Answers

2
Yola On Best Solutions

AVL tree maintains certain invariant. You just need to check it after every insertion or deletion, and don't waste your time trying to incorporate another implementation of AVL tree into your project.