human
Complete the below
def get_proctored_exam_results(course_key, features):

    ''''Return info about proctored exam results in a course as a dict.'
    '''
 ... Give me a the Python code you requested?
assistant
#Here is the Python code you requested.
    def extract_student(exam_attempt, features):
        '\n                                Build    dict    containing    information    about    a    single    student    exam_attempt.\n                                '
        proctored_exam = dict(((feature, exam_attempt.get(feature)) for feature in features if (feature in exam_attempt)))
        proctored_exam.update({'exam_name': exam_attempt.get('proctored_exam').get('exam_name')})
        proctored_exam.update({'user_email': exam_attempt.get('user').get('email')})
        return proctored_exam
    exam_attempts = get_all_exam_attempts(course_key)
    return [extract_student(exam_attempt, features) for exam_attempt in exam_attempts]