Some code to finish part 1