Roughly based off of the assignment for CS 344 at OSU