makeNstr function

creates a string that is a repeat of a substring