binary tree sum and max