Tomi Chen

elves.py

December 2019 Source

Archived Miscellaneous

elves.py is a Python script I wrote to brute force an extra credit logic problem my math teacher assigned over winter break. Essentially, it loops through every single possible combination of values and checks each one against the limitations given by the problem. Some manual optimization on the search space was necessary, but it did return the correct result in the end.

I submitted a copy of the code along with an explanation, and even got extra credit on the extra credit. I also submitted this as a creative product for a summer camp where I go into a bit more detail about what happened.