added user prompt for number

also tightened up the logic