Lab No 7 Round Robin Algorithm For Operating System

Lab No 7 Round Robin Algorithm Round-Robin is one of the algorithms employed by process and network schedulers incomputing. As the term is generally used, time slices are assigned to each process in equal portions and in circular order, handling all processes without priority (also known as cyclic executive). Round-robin scheduling is simple, easy to implement, and starvation-free. Round-robin scheduling can also be applied to other scheduling problems, such as data packet scheduling in computer networks. It is anOperating System concept. The name of the algorithm comes from the round-robin principle known from other fields, where each person takes an equal share of something in turn. Direction: Round RobinAlgorithm in C++ #include using namespace std; int main() { int bt[20],p[20],wt[20],tat[20],pr[20],i,j,n,total=0,pos,temp,avg_wt,avg_tat; cout<<"Enter Total Number of Process:"; cin>>n; cout<<"nEnter Burst Time and Priorityn"; for(i=0;i>bt[i]; cout<<"Priority:"; cin>>pr[i]; p[i]=i+1; //contains process number } //sorting burst time, priority and process number in ascending order using selection sort for(i=0;iMichael Elkan