binary tree distance