Race-Style Random Drawing

Science is a very collaborative process, but not all of the tasks are glamorous or fun (e.g., putting an EEG cap on a research subject). To help encourage everyone in the lab to help each other out, we developed a simple reward system. Anytime someone helped out another lab member with something, they got a point on the scoreboard. At the end of the month we had a drawing. Each person’s name was entered into the drawing as many times as they had points (i.e., more points == more chances to win). We then picked a winner and everyone else in the lab took that person out for drinks.

We used to just use a hat and scraps of paper, the old fashioned way. We got tired of ripping up perfectly good scratch paper, and decided to go high-tech. Inspired by a horse-racing carnival game at the WI State Fair, I quickly coded up a browser-based, race-style random drawing app. Each person picks a character, a color, and enters their point total for the month. When everyone is on the line, the race is run (purely random steps forward), and the first to cross the line wins!

You can have your own races here. Should you want to change anything about it (e.g., add new icons), the code is available on GitHub.

This was written long before I started a serious study of software development, so it’s just the prettiest code, but it gets the job done!