So we are trying to find this red line's length.
We can either find it directly, or use the blue line firs, and then use it as a leg for the green triangle.
So the blue leg is a hypotenuse for two of the edges. So:
from the Pythagorean Theorem
OR
Which works out to:
So now that we have that, using the Pythagorean Theorem again gives:
So the length of the red line is found that way.
But wait! There's more!
As it turns out, the red line can be found with an easier way that works with cubes and boxes (cuboids). It's really easy:
Where a, b, and c are all 10m, and d is the red line. This greatly reduces the math:
which gives the same answer as above, which you can see.