The topological sorting algorithm can help us solve this problem. \begin {itemize} \item Build a digraph to represent the course prerequisite requirements. The nine courses are vertices in the digraph. If a course A is a prerequisite for another course B, the digraph has a directed edge from A to~B. \item Apply the topological sorting algorithm on this digraph. The result is one possible sequence of courses for Bob. \end {itemize} For the give set of prerequisites, the solution is not unique. For example, one possible solution is LA15, LA16, LA22, LA31, LA32, LA126, LA127, LA141, LA169. Another solution is LA15, LA16, LA127, LA31, LA32, LA169, LA22, LA126, LA141.