Live data from Hacker News

Ain't it funny how the knight moves?

funnyhowtheknightmoves.com

181–190 of 211 posts

Re: Ain't it funny how the knight moves?

#181
post #95

If you'd like "easy mode," such that the queen's squares are highlighted: ((sq) => { let board = document.querySelector('div.m-auto'); sq.forEach(s => board.querySelector('[data-squareid="'+s+'"]').style.backgroundColor='red'); })(["d8", "d7", "d6", "d4", "d3", "d2", "d1", "e6", "f7", "g8", "c6", "b7", "a8", "c5", "b5", "a5", "e5", "f5", "g5", "h5", "c4", "b3", "a2", "e4", "f3", "g2", "h1"]) I found that to be the mi…

[deleted]

Re: Ain't it funny how the knight moves?

#182
post #95

If you'd like "easy mode," such that the queen's squares are highlighted: ((sq) => { let board = document.querySelector('div.m-auto'); sq.forEach(s => board.querySelector('[data-squareid="'+s+'"]').style.backgroundColor='red'); })(["d8", "d7", "d6", "d4", "d3", "d2", "d1", "e6", "f7", "g8", "c6", "b7", "a8", "c5", "b5", "a5", "e5", "f5", "g5", "h5", "c4", "b3", "a2", "e4", "f3", "g2", "h1"]) I found that to be the mi…

I added a graph and a screenshot : https://gist.github.com/unrealwill/07069676a577f6dfbc3555369...

Re: Ain't it funny how the knight moves?

#183
post #180

Earlier quoted context omitted.

Holy... is that what you're supposed to do?!? No wonder the bar wasn't growing even though I jumped to every possible square -.-

Just curious, what exactly did you think "in order, right to left, top to bottom" was supposed to mean?

I thought it meant "goto the bottom left corner" or "goto the top left corner then goto the bottom left corner." or "mark all legal tiles visited".

There's no hint in the help that you're suppose to goto the tile coordinate specified by the little box in the bottom left corner. I'm not even technically sure that's what the "f8" at the beginning is for since the help doesn't mention it.

Re: Ain't it funny how the knight moves?

#184

Earlier quoted context omitted.

Have to raise my hand then to shock you.. what else should the coordinate that is also indicated on the axes mean? > to every square in order, right to left, top to bottom Added to that immediately. shrug But yeah as the title says, one realizes quickly that knight moves pretty strange so got bored after 5 targets and did something more exciting: wrote a Python script that prints me the moves from and to any coordina…

Have to raise my hand then to shock you.. what else should the coordinate that is also indicated on the axes mean? Yeah, but it's not clear that the instructions text is talking about that symbol, *because it doesn't say so* explicitly. Sometimes a small level of information redundancy is good for communicating with humans, instead of forcing them to make the correct inferences in place.

It wouldn't technically be redundant, the help instructions are ambiguous.

Re: Ain't it funny how the knight moves?

#185
post #180

Earlier quoted context omitted.

Holy... is that what you're supposed to do?!? No wonder the bar wasn't growing even though I jumped to every possible square -.-

Just curious, what exactly did you think "in order, right to left, top to bottom" was supposed to mean?

Like move the Knight to every square on the board, in a certain order, but skipping some. I didn't notice the "f8" at the bottom until I read the comments.

Re: Ain't it funny how the knight moves?

#186

I think the instructions should be: Move to the square indicated below the board without moving to a square the queen can capture and without capturing the queen. Once accomplished a new square will be indicated. Repeat until all possible squares are done.

Kind of makes you appreciate the amount of work most games put into UI design. This game mechanic is very simple and it still needed documentation... And the documentation wasn't enough! Immensely complex games these days are so good at providing hints and player feedback that many often don't need their tutorial levels.

IMO the documentation says to do something completely different than what the apparent goal actually is.

Re: Ain't it funny how the knight moves?

#189
Good exercise! 5:29 on the first try (FM),

3:27 on 2nd try once I realized we have to move the knight to non attacked squares from top right to left bottom

At first I thought I had to implement the knights walk by myself so wasted about 30 seconds on understanding the instructions.

Re: Ain't it funny how the knight moves?

#190
post #107

Earlier quoted context omitted.

It depends upon what you are trying to visualize. If you are trying to visualize the pattern of the knight's moves, e.g. how to reach a specific square using a sequence of moves, then highlighting the target would be more valuable. The displacement matters, not the absolute positions. The absolute positions are more of a hindrance since it makes it more difficult to generalize the sequence of moves.

The point is learning to generalize the sequence of moves, and that's why it doesn't give any visual cue.

In a real chess position, where the knight must go is the easy part because there something interesting to do there (like capturing a piece). The problem here is that the chessboard is empty, so it's difficult to remember where you should go.

The interesting part is finding the knight trajectory, reading the notation is boring and easy.

(If the point of the exercise was to read the notation, it should be a different game, like clicking that square as fast as possible.)

Post reply on HN