CS homework 7

A computer is given a set of jobs to complete with the goal of
completing the entire set as many times as possible. Every job in the
set must be completed before the next execution of the set can be
started. Each job in the set is represented by the time it takes to
complete it. This computer has a time limit during which it attempts
complete the set as many times as possible. It is possible that the
computer will reach the time limit without completing all of the jobs
in the set.