def int_or_chr_key(s):
    """Return a sortable value as an integer if possible otherwise, convert the
       character to an integer"""
    try:
        return int(s)
    except Exception:
        return ord(s)