Skip to main content
๐Ÿ“œ WAYPOINT LESSON

Checkpoint โ€” Collections

โญ beginnerโณ 20 min read๐Ÿ“ Lesson 33 of 85

A gradebook: per-student averages, a class ranking, and honors detection โ€” Dictionary, List, and a little LINQ-free aggregation.

Checkpoint: the gradebook

Task: implement three methods against Dictionary<string, List<int>> (student โ†’ scores):

  1. static Dictionary<string, double> Averages(Dictionary<string, List<int>> gradebook) โ€” each student's mean score (double division!). A student with an empty score list must NOT appear.
  2. static List<string> Honors(Dictionary<string, List<int>> gradebook) โ€” students whose average is โ‰ฅ 90, ordered by descending average then ascending name.
  3. static string TopStudent(Dictionary<string, List<int>> gradebook) โ€” the name with the highest average; on a tie, alphabetically first. Null/empty gradebook returns "".