I got stuck with this puzzle.
I can't get understand how could be the Example 5 test case result 18?
X -5, Y -3
X -9, Y 2
X 3, Y -4
The test said, 18 the cable length.
I tried to get this result in a piece of paper on a coordinate system, but can't get the 18.
I calculate is 21.
I think I miss something, but don't find what is that.
Please help me,
Thank you in advance!