added class that generates number up to a certain limit.