class Solution: def maxAverageRatio(self, classes: List[List[int]], extraStudents: int) -> float: def calcGain(studs, total): return -1 * ((studs + 1) / (total + 1) - studs / total) ratios = [(calcGain(x[0], x[1]), ...