I\'m trying to know whether my code is right or wrong with your help, because sadly I can\'t run it to check.
There are no compile errors. What I\'m trying to do is to
Looks fine to me, although I'd personally change the last bit to:
return Math.max(heightLeft, heightRight) + 1;
I'm concerned that you can't run it at all though... why can you not write unit tests around this? I'd be nervous of any code I can't test :)