1 / 2
Feb 2020

Is there a fault in the official test output for PC8C Cave Crisis10?

This test case:

964 4
10 144 381 121 248 1 265 12 71 101 59 92 53 227 -104 379 -50 480 172 388 233
5 146 -64 171 -284 280 -347 415 -289 328 0
5 351 139 225 -24 338 -75 579 93 456 183
7 119 131 21 -127 123 -207 104 -262 161 -226 328 -48 328 120

Looks like this:

?
Where object 1 is brown, 2 is blue, 3 is green, and 4 is magenta.

The tunnel is 964 wide, so it goes from y = -482 to y = +482.

The widest gap is at the top (my diagram is inverted, so negative at the top), and is 482 - 347 = 135 units in size. That’s the diameter of R2D2, but the answer wants the radius, which is 135 / 2 = 67.50.

Except the official output has 64.73. Huh? (But perhaps that explains why there were no successful submissions2 during the contest.)

Or have I misunderstood something or made a mistake?

  • created

    Feb '20
  • last reply

    Jan '24
  • 1

    reply

  • 792

    views

  • 1

    user

  • 2

    links

3 years later

My mistake. I hadn’t considered how close obstacles are to R2D2’s starting position. In the above example, the closest obstacle is 64.73 units from the origin.

(Thank you @Oleg)