Max path in a tree