JBean's submission for R Programming Assignment 2