adding isSameTree