Week 2 R programming assignment