import re


def admitted_faster_to_qed(s):
    """Replaces instances of "Admitted. (* faster *)" with "Qed."

    >>> admitted_faster_to_qed('asd Admitted. (* faster *)')
    'asd Qed.'

    >>> admitted_faster_to_qed('asd Admitted.  (*   faStEr*)')
    'asd Qed.'

    >>> admitted_faster_to_qed('asd Admitted. (* a lot faster *)')
    'asd Admitted. (* a lot faster *)'

    >>> admitted_faster_to_qed('asd Admitted.(*  otheRwise proof 	tOo   sLow*) asd2')
    'asd Qed. asd2'
    """

    result = s
    result = re.sub(
        r'Admitted[.]\s*[(][*]\s*(?i)faster\s*[*][)]',
        'Qed.',
        result)
    result = re.sub(
        r'Admitted[.]\s*[(][*]\s*(?i)otherwise\s*proof\s*too\s*slow[*][)]',
        'Qed.',
        result)
    return result