Search method for the binary tree.