Shadows of the Knight - Episode 1 - Puzzle discussion

Feel free to send your feedback or ask some help here!


Level 2 of this one doesn’t seem to be anywhere. Is it normal ?


It is called triangulation, un the very hard puzzle section


Oh, right. Thanks !

1 Like

I’m running this one in Go. Has anyone had this error?

Invalid input: expected ‘x y’ but got: ‘3 5’.

Are 3 5 valid coordinates in the test you are running ? If so, have you put the end line character after the line you print ?

Got it, just let Println add the space for you, as in fmt.Println(x, y) instead of fmt.Println(x, " ", y)

Did it with four IFs, seven assignments, and two simple mathematical operations. I dare you to do better, I DOUBLE DARE YOU, CODEHACKER! :smiley:

Seriously, bisection method is more than enough for this one. Skynet: the Virus have given me much more pain.

P.S. Am I qualified to be batman now? :slight_smile:


Alright guys, got all the tests but the last one to pass. I think this is because of truncation in int divisions. (ie 3/2=1).

Any idea on this matter ?

1 Like

I had a problem with the second to last test, ‘Evasive’, due to integer division. I solved it by doing double division and taking the ceil. Also, it might be a good idea to make sure you always move at least one step in the desired direction, i.e. step = max(1, step). Hope this helps!


I used integer division and everything worked out fine.


passed every test, on puzzle choosing screen it says 60\60 CP (whatever that it), 2\2 achievements, but 0% done. why?

same here… how come?

Just wait a couple of hours. Problem fixed by itself after some time passed.

I tried bissection but what about the “evasive” test?
When the bomb is at the top left forner

Bisection method? I’m afraid I’m not a mathematician. Are there any sites or links that can explain this concept?

If I can give you a hint, activate debug mode, it’ll be clearer :wink:
You just need to divide the distance by two each time you jump and you’ll be alright

I meant with the bissection methode (dividing the distance by two) because the bomb is at the top of the building (y = 0) on the “evasive” test, you’ll need 8 jumps to find it. But you are allowed to do only 7 jumps :smiley:
So you need to do a little trick about this one :stuck_out_tongue:

1 Like

I just checked my code, i only need 7 jump and I did the bissection method like you described, with no further tricks :stuck_out_tongue:

1 Like

Agree, the same for me. simple (minCoord + maxCoord) / 2 does the trick pretty well.

Probably some language related stuff like rounding?