I recently got into Rubik’s cubes using the beginner’s method (thank you badmephisto for the tutorial). Then I started learning learning F2L so I could complete the middle layers quicker. But while F2L is more intuitive, solving the last layer is more algorithmic.
I want to use 4LLL to solve the last layer because I’d “only” have to learn about 16 algorithms compared to the 78 algorithms for 2LLL. But it takes time to solve the cube to the point where I would need to use one of the algorithms I’m trying to memorize. So I wanted to just study the algorithms themselves, flashcard style. To do that I made a simple page.
The page itself is here, and I made a GitHub repo for the page (not sure why) here.
The application is very simple, and in fact reminds me of a very limited type of Turtle Graphics.
Continue reading Following Directions (repeatedly)
I heard recently about an interview problem involving matching braces in a string. Checking to see if all the braces in a string are paired up in the proper order. Seemed like an interesting, and short, challenge.
Examples of strings with proper brace matching:
Examples of strings without proper brace matching:
Continue reading Matching braces in a string
I’d like to start posting some shorter entries. Hopefully that will be more conducive to making posts more often. I’m going to start tagging these as Short Code entries.
For this first one I came across a challenge on reddit about converting a quantity of minutes into a readable string, paraphrasing here:
Write a function that takes in a number of minutes as an integer and returns a string of the format “# years, # months, # days, # hours, #minutes”.
Continue reading Converting minutes into a readable string