solutions to ex1