Prog. assignment 2 for R programming: Coursera.