def sort_by_announcement(courses):
 key = (lambda course: course.sorting_score)
 courses = sorted(courses, key=key)
 return courses

def sort_by_announcement ( courses ) : key = ( lambda course : course . sorting_score ) courses = sorted ( courses , key = key ) return courses
sorts a list of courses by their announcement date .