add solution for validate_binary_search_tree