Round 1 Challenge

A special JRMPC Organiser application is provided for the competition. This application allows you to do the following:

  1. Choose a board (or “map”) to play with from a dropdown list.
  2. Choose a strategy (or “mind”) to execute from a dropdown list.
  3. Start the board execution, stop the execution, or reset the board.
  4. You can also step through the execution cell by cell.
  5. You can open the System Browser (“Browse Mind”) to the code for all the robot minds, including the all-important base class #RobotMind.
  6. There’s also a history of the map execution where you can see every step. (The steps are ordered from most recent to oldest. Each step shows the elapsed execution time and the current score.)
  7. To install the JRMPC Organiser application, start with a fresh Pharo 7.0 (64-bit) image. Then, File In the file. (You can simply drag-and-drop the file on top of the Pharo window and select “FileIn entire file”.)

Wait for about half a minute while the File In initialization is taking place. You should then see a new menu item called ‘JRMPC’ in Pharo. Click on the submenu item ‘Robots’ to open the application.

A collection of sample boards and strategies have been provided for you to experiment with. You should eventually create your own strategy by subclassing #RobotMind. This new strategy will be your solution to submit to the JRMPC website.

A note about the colours of the cells:

  • white cells have zero energy value
  • cells with various shades of red have values greater than zero — the darker the shade, the higher the value
  • yellow cells have extraordinarily high values (greater than 100)

The cell which the robot occupies is green. (The letter ‘A’ signifies the identifier for this particular robot. There may be other robots in the future.)

You will notice a special facility called “Ghost” keys. You can navigate the robot manually by pressing the arrow icons (up, down, left, right). With Ghost keys enabled, the robot can be moved without taking any action on the cells, i.e., consuming the energy value of the cell. With Ghost keys disabled, the robot will consume the values.

Another special facility is “Debug” mode. With Debug enabled, when you begin board execution, you will be taken into the Debugger. The method #mindDoOneCycle is your starting point for exploring and modifying the three main entry points for your competition strategy. These entry points are:

  • #setupOn:
  • #recoverOn:
  • #determineDirectionForRobot:

To understand what these entry points do, go into the System Browser and look at these methods for the #RobotMind class. At the top of each method, you will see a comment like “COMPETITION ENTRIES MAY/MUST OVERRIDE THIS METHOD.” The description tells you all you need to know.

Look at these methods for the sample strategies like #BestNeighborMind and #RandomWalkMind to see how they can work. Your job is to improve upon these methods for your strategy.

Hover the cursor over any cell and you’ll see its coordinates and energy value in a tooltip.

Tools like step-by-step execution, Ghost keys, Debug mode, and cell coordinates tooltip are there to help you experiment and develop your strategy.

Use the System Browser to File Out your solution strategy. So, for example, if your new strategy is called ‘MyTeamMind’ and you wish to File Out the strategy for submission to JRMPC, right-click on the class, select Extra and then File Out. A file called should appear in the same folder as your Pharo image.

How to File Out — go fullscreen should be relocated and renamed to, where xxxxyyyyyy is the 10-character secure code you were assigned when you first registered your team. ‘S1’ signifies Round 1.

If you misplaced your secure code, email me (using the Captain’s registered email address) and I’ll give it to you again.

(You may want to create a script for renaming the file so that you don’t enter your secure code incorrectly. An incorrect secure code will disqualify your solution.)

When you’re ready to submit the solution, log into your account and select ‘Submission’ from the menu.

For Round 1, the deadline for submission is Friday, February 7, 2020 at 9:00 pm EST. Right afterwards, a blog post showing the details for Round 2 will be published.

When we receive your submission, we will run your code against our Round 1 board, which you’ve not seen. This will determine the score for your team in this round. The object is to get the highest score possible by navigating the robot around the board according to your strategy.

If any of this is unclear, please email me for clarification. It is vital that you understand the competition procedure.

Good luck!