Skip to content

Simulate SJF ( Shortest Job First ) and RR ( Round Robin ) CPU scheduling algorithm

Notifications You must be signed in to change notification settings

EbadiDev/CPU-Scheduling-Calculation

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Make a program that simulate SJF ( Shortest Job First ) and RR ( Round Robin ) CPU scheduling algorithm

how it's works?

for SJF :

Process name Arrive time Burst time
P1 0 4
P2 2 1
P3 0 2
P4 4 6
       P3          P2         P1         P4
|0----####---2----####---3---####---7---####---13-|

Return time (Turnaround time) formula:

Turnaround Time = Completion Time - Arrival Time

Where,
Completion Time: The time when a process completes its execution
Arrival Time: The time when a process arrives in the ready queue

Average Turnaround Time = (Sum of Turnaround Times for all processes) / (Number of processes)

About

Simulate SJF ( Shortest Job First ) and RR ( Round Robin ) CPU scheduling algorithm

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages