Make sure that your resulting number does not start with a zero (unless it is exactly 0) and is in the range described in the problem.