def _nth(n):
    """Convert an integer to a string with ordinal letters
    For example, `_nth(1)` returns "1st", `_nth(2)` returns "2nd", etc.
    """
    t = 'th'
    a = {'11': t, '12': t, '13': t, '1': 'st', '2': 'nd', '3': 'rd'}
    n = str(int(n))
    return n + a.get(n[-2:], a.get(n[-1], t))
