BST + treesort