Added a timesLimit() function