Add exercise 2 without non-numeric termination.