Obtener estudiantes con nombres y sus notas más altas

Crea una función que reciba un arreglo de objetos como { name: "John", notes: [3, 5, 4] } y devuelva un arreglo de objetos como { name: "John", topNote: 5 }.

Si el estudiante no tiene notas (un arreglo vacío), supongamos que topNote: 0.

Ejemplos

getStudentsWithNamesAndTopNotes([
  { "name": "John", "notes": [3, 5, 4] },
  { "name": "Max", "notes": [1, 4, 6] },
  { "name": "Zygmund", "notes": [1, 2, 3] }
])
➞ [
  { "name": "John", "topNote": 5 },
  { "name": "Max", "topNote": 6 },
  { "name": "Zygmund", "topNote": 3 }
]

Notas

Intenta resolver este desafío con una función flecha.