Microsoft | Onsite | Job Scheudling Quesiton
Difficulty: MEDIUMCategory: InterviewExperienceFrequency: 1Asked On 2022-03-15Added By Anonymous
Source: Link
Company: Microsoft
Role: unknown
Interview Stage: Onsite
Location: unknown
Year: unknown
Original Post Content:
You have a set of jobs J = [J_1..J_n]. Each job takes an arbitrary number of minutes, [m_1..m_n] to execute.
Let's say that the jobs can execute in parallel on nodes [N_1..N_k]. Assume we have a maximum wallclock time budget T, that is the maximum allowable elapsed time since the first job started executing. Write a function to give the minimum number of nodes needed to execute these n jobs within time budget T.