This is easiest done as an array. The problem you will have with the above is that numbers will only contain the last input digit since its overwritten during each iteration of the loop. Create an array prior to the loop, and insert each iteration as a new item within the array. After the loop, you can then loop again and print each item within the array.
You should do some error checking as well on the input, but I'm guessing that this is a school assignment, in which case exceptions may not yet have been covered.