Update sameTree