assignment 2 - Coursera R programming