Implement a subject scheduler using the topological sorting algorithm. The program shall prompt for an
input file containing the subjects in the set and the partial ordering of subjects. A subject in the input
file shall be of the form (number, subject) where number is an integer assigned to the subject and
subject is the course identifier [e.g. (1, CS 1)]. Every (number, subject) pair must be placed on a
separate line in the input file. To terminate the input, use (0, 0). Prerequisites of subjects shall be
retrieved also from the same file. A prerequisite definition must be of the form (i, j), one line per pair,
where i is the number assigned to the prerequisite of subject numbered j. Also terminate the input
using (0, 0).
The output is also a file where the name will be asked from the user. The output shall bear the semester
number (just an auto-number from 1 to n) along with the subjects for the semester in table form.
For simplicity, we won’t consider here year level requisites and seasonal subjects.
please help me...