solve `Exercise 1: Pascal’s Triangle'