I think that at 6:40 you mixed up the two input : The first input of the subtraction is the end point and not the starting point.
You are absolutely correct! Well spotted Joseph👍🏻