Exercise 2.3: use CPS to handle non update case