They are not actually using each other's private numbers in the calculation of the shared secret - the video just substituted the values to show how they are effectively ending up with the same calculation, even though they each only know one of the factors explicitly.
I tried following this through with a calculator and couldn't get the sums to work out. It turns out this video was a rough draft containing mistakes, and the final version (with valid arithmetic) is here:
www.youtube.com/watch?v=YEBfamv-_do
The author also admitted his explanation of how the shared secret is calculated was confusing, and reworked that in the final version. The paint analogy is a really nice explanation of the principle, however.
(, Mon 28 Jun 2021, 23:17, Reply)