def checkPrefix(s, prefix):
    """
    Return a pair (hasPrefix, rest).
    If prefix is a prefix of s:
        hasPrefix is True
        rest is everything after the prefix
    Else:
        hasPrefix is False
        rest is s
    """

    if s.startswith(prefix):
        return (True, s[len(prefix):])
    else:
        return (False, s)