finish week4 programming assignment