A simple prime number generator. (Self practice exercise)