The second week of my internship here at LASP was super cool, I started getting into the flow of working and got tons done. I started the week finishing a script-parsing project that was to get warmed up coding with python. The project was is interesting and reminded me of a lot of python syntax and command line parsing. Next up was a practice in object oriented programming and inheritance that was pretty easy and only took me a day. Then for the last three days of the week I tackled a multiprocessing program that was designed to solve this puzzle.
The goal of the puzzle is to put the numbers 1-9 into the blank squares and try to make them satisfy the equation and equal 66. The program was relatively simple, but computing almost a billion permutations of the numbers 1-9 takes some serious processing power. This problem without multiprocessing (using more than one core of the computer to do equations) takes almost 45 minutes to find all 128 possible answers using order of operations and 144 without order of operations, but by optimizing and using multiprocessing I was able to get it down to around 5 minutes. This was without using convenient python libraries that could solve all the answers in under a second, because although those libraries (itertools) are optimized, they are almost impossible to use with multiprocessing.
After finishing the multiprocessing puzzle program I moved on to capture the flag, designed to give us interns practice at finding information through the command line. Super interesting stuff. This is a picture of the outside of my office–I work where they keep the aliens.
The inflatable alien is hilarious!