On June 1, 2016, Wild Noodle introduced its summer competition. This competition consisted of 25 levels, with increasing complexity, using Herbert and the “H” language. Herbert’s “H” language has three statements: l (left) r (right) and s (straight) and they are arranged using procedures and parameters to achieve the desired goal of solving the puzzle in the most efficient manner; otherwise known as optimization .
Though the goal of the competition seemed pretty straightforward, I was left thinking about the objectives of the game. I pondered about various options for developing a square. For example, to create a simple box, I could program Herbert, using the following order of statements:
This program would take approximately 11 Bytes to complete and if I wanted a bigger square that this would add to the number of Bytes required. Thus, if my desired goal was to make a square as efficient as possible, well this was not the answer, but in contrast, it was a fairly easy to program. But if my goal was to create square with the least amount of Bytes then I would possibly use the following program to achieve my goal:
In the program above, I am using a technique called recursion . I am asking Herbert to do the side of the square along with a turn to call itself indefinitely. This program took only 6 bytes. Yet again, if I wanted to make my square 5 or 10 times larger, well this would take additional bytes, again challenging the goal of efficiency.
Though this program took 15 Bytes, it would eventually be more efficient than the previous program if I wanted a box larger than 11 s (statements). This program allows me to program the number of steps forward Herbert should go for each side of the square.
Yet Herbert has so many options to solve the puzzle of the square. Here are just a few ways to draw a square of size 10:
As I explored the myriad square creating options, I realized the beauty of Herbert. Though the Herbert competition primary objective was to solve the given problems in the most efficient manner, the Herbert program had the ability to teach me how to think about variability of options to solve one problem and that learning the different options, allowed me to understand the complexities of problem solving. It also allowed me to expand my ability to think outside the box. What if I wanted to take my box and give it fancy corners or make many boxes? The more options, I created, the wider my scope to find solutions. Look at my designs below:
Box with Fancy Corners
Many Boxes with Fancy Corners
Ultimately, Herbert and its “H” language, not only allowed me to think about the complexities of problem solving, but it also allowed me to explore the art of computer programming, the art to develop and design…Hello World!