![]() ![]() For Loop for user to input info about the processes Printf("\nEnter the total number of processes: ") ![]() function grabs arrival and burst times of each process and stores it in its respective array Int i, n, j, m, min, sum = 0, x = 1, btTally = 0, p, bt, at, wt, tat, ta = 0 tat - time spent by process in cpu array wt - the time taken for the process to start from it's arrival time array This is all then compiled in the end and shown. ![]() The first phase involves arranging the program by arrival times and the 2nd phase arranges them by burst times given that their arrival times are lower than the time for the previous process to complete. The shortest job first algorithm program takes in inputs for the arrival and burst times of the required number of processes and arranges the processes in 2 phases. I have created a C Program to simulate the Non-Preemptive Shortest Job First Algorithm but it has bugs with certain inputs. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |