assignment 2 for coursera course R programming by alessia574