Code written as part of the Summer Program for Incoming Students at UC San Diego