Add solution for problem A3