def _ordinal(n):
idx = int((n//<NUM_LIT:10> % <NUM_LIT:10> != <NUM_LIT:1>) * (n % <NUM_LIT:10> < <NUM_LIT:4>) * n % <NUM_LIT:10>)<EOL>return '<STR_LIT>'.format(n, "<STR_LIT>"[idx::<NUM_LIT:4>])<EOL>
Returns the ordinal string for a given integer

    See https://stackoverflow.com/a/20007730/1307974

    Parameters
    ----------
    n : `int`
        the number to convert to ordinal

    Examples
    --------
    >>> _ordinal(11)
    '11th'
    >>> _ordinal(102)
    '102nd'