Accepted UVa 12347 Binary Search Tree