def prefix(values, content):

    """
    Discover start and separate from content.
    Will raise ValueError if none of the starts match.
    """

    for value in values:

        if content.startswith(value):

            break

    else:

        raise ValueError('invalid starts')

    content = content[len(value):]

    return (value, content)