def string_to_int_list(line) -> list[int]:
    """
    Given a line containing integers, return a list of ints.

    Return list[int]: A list of integers from the string.

    >>> string_to_int_list('22 13 17 11  0')
    [22, 13, 17, 11, 0]
    >>> string_to_int_list('22,13,17,11,0')
    [22, 13, 17, 11, 0]
    """
    line = line.strip()
    if ',' in line:
        return [int(x) for x in line.split(',')]
    else:
        return [int(x) for x in line.split()]