Amazon Interview Question

Find the distance between two nodes of a binary tree. A leetcode hard question related to string and python compiler.