#C14343. Find Employee with Maximum Overtime

    ID: 43982 Type: Default 1000ms 256MiB

Find Employee with Maximum Overtime

Find Employee with Maximum Overtime

Given a list of integers representing the total hours worked by each employee, your task is to determine the index of the employee who worked the most overtime. Overtime is defined as the number of hours worked beyond 40. In other words, for an employee with working hours \(h\), the overtime is \(h - 40\) if \(h > 40\), otherwise it is 0.

If no employee has worked overtime (i.e. all hours are less than or equal to 40), output None. In case of a tie for the highest overtime, return the smallest index among them.

Example: If the input is 40 45 50 42 60, then the overtime for each employee is [0, 5, 10, 2, 20] respectively. The maximum overtime is 20 at index 4, so the output should be 4.

inputFormat

Input is provided as a single line of space-separated integers. Each integer represents the total number of hours worked by an employee.

outputFormat

Output a single value: the 0-indexed position of the employee with the maximum overtime. If no employee worked overtime, output None.

## sample
40 45 50 42 60
4