def course_key(course):
  """Returns the course key.

  Args:
    course: The course object.

  Returns:
    A key that may be used to sort course objects.
  """
  return (course.campus, course.department, course.code)