Done some work on problem 7
[ou-summer-of-code-2017.git] / 05-display-board / display-board-solution.ipynb
index cf34334661a252610151d79bcfa30a0534ddefca..495c11085feacc88252626b2a695a5945cf3e753 100644 (file)
@@ -6,14 +6,14 @@
    "source": [
     "# Laser display boards\n",
     "\n",
-    "You need to navigate your way through Heathwick Airport to find the correct gate. The bad news is that all the display boards have gone down. The good news is that the terminal staff are handing out the machine-code instructions to generate the messages on the board. \n",
+    "You're off on your first sightseening trip of your holiday and you need to catch the right llama-rickshaw to get there. You arrive all keen at the llama-rickshaw station, only to find a scene of chaos. The bad news is that there are lots of llama-rickshaws heading to different places. The good news is that above each bay is a display board that shows where that llama-rickshaw is heading. The bad news is that all the display boards have gone down. The good news is that the station staff are handing out the machine-code instructions to generate the messages on the board. \n",
     "\n",
     "Given your l33t haxor skilz, it will be no problem to recreate the messages on the display boards.\n",
     "\n",
     "The board is grid, 80 pixels wide and 8 pixels tall, with row 1 being the top row and column 1 being the left column. The pixels are changed with these commands:\n",
     "\n",
     "* `top A B` switches the state of the pixels in the topmost row from columns A to B inclusive. If a pixel was lit, it becomes dark; if it was dark, it becomes lit.\n",
-    "* `left A B` is similar, but works on the left edge, toggling the state of pixles in the leftmost column in rows A to B inclusive. \n",
+    "* `left A B` is similar, but works on the left edge, toggling the state of pixels in the leftmost column in rows A to B inclusive. \n",
     "* `rotate column A B` rotates column A by B spaces down. Pixels that are moved beyond the bottom edge \"wrap around\" to the top edge.\n",
     "* `rotate row A B` rotates row A by B spaces to the right. Pixels that are moved beyond the right edge \"wrap around\" to the left edge.\n",
     "\n",
@@ -51,7 +51,7 @@
     ".*........\n",
     "```\n",
     "\n",
-    "* `rotate column 8 1` moves the one lit pixel in column 8 down one row.\n",
+    "* `rotate column 8 5` moves the one lit pixel in column 8 down five rows, wrapping it all the way around the display and leaving the board with one lit pixel in that column one row lower.\n",
     "```\n",
     "*.....*.**\n",
     ".......*..\n",
@@ -81,7 +81,7 @@
    "metadata": {},
    "source": [
     "## Part 1\n",
-    "You're standing in front of gate 9¾. You have [the instructions](05-pixels.txt). How many pixels would be lit on the board, if it was working?"
+    "You're standing in front of gate 9¾. You have [the instructions](05-pixels.txt). How many pixels would be lit on the board, if it were working?"
    ]
   },
   {