Gainsight interview question

program to find diameter of a binary tree