Skip to content

Instantly share code, notes, and snippets.

@skwak
Last active August 29, 2015 14:02
Show Gist options
  • Save skwak/84acb1501a25824a4481 to your computer and use it in GitHub Desktop.
Save skwak/84acb1501a25824a4481 to your computer and use it in GitHub Desktop.
Logic Assessment #2
  1. The first two gnomes make a line parallel to the cave entrance. Later gnomes join the line at the dividing point between red & blue foreheads. If the foreheads are the same color, a gnome goes to one of the line's ends.

  2. My "ah-ha" moment came when I was playing kickball at a friend's party. In picking teams, team leaders stood at one end, with potential teammates sitting parallel to them. So, I imagined gnomes leaving a cave to enter a kickball field. Maybe the first two gnomes who leave the cave have red & blue foreheads. Then the next gnome with a blue forehead goes in between the two cavemen so the formation is now RBB. If the foreheads are the same color, for instance BBB, and a gnome with a red forehead comes out, the gnome goes left or right to form RBBB or BBBR. I imagined various combinations, and this method seems to work. Now the gnomes can play kickball.

  3. a) If the gnomes "automatically sort themselves", maybe any kind of sorting is possible, b) Each gnome stares at another gnome and sees the reflection of his/her forehead in the other gnome's eye.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment