Question Number 2 Below mentioned is an algorithm. Step1:Get the number of process. Step2:Get the id and service time for each process.


i need solution of Part 3 and 4


Question Number 2<br>Below mentioned is an algorithm.<br>Step1:Get the number of process.<br>Step2:Get the id and service time for each process.<br>

Extracted text: Question Number 2 Below mentioned is an algorithm. Step1:Get the number of process. Step2:Get the id and service time for each process.
Step3:Initially the waiting time of first short process as 0 and total time of first<br>short is process the service time of that process.<br>Step4:Calculate the total time and waiting time of remaining process.<br>Step5:Waiting time of one process is the total time of the previous process.<br>Step6:Total time of process is calculated by adding the waiting time and service<br>time of each process.<br>Step7:Total waiting time calculated by adding the waiting time of cach process.<br>Step8:Total turnaround time calculated by adding all total time of cach process.<br>Step9:calculate average waiting time by dividing the total waiting time by total<br>number of process.<br>Step10:Calculate average turnaround time by dividing the total waiting time by<br>total number of process.<br>Step11:Display the result according to Table 2<br>Process<br>Arrival Time<br>Burst Time<br>P1<br>P2<br>45<br>P3<br>1<br>64<br>P4<br>6.<br>4<br>P5<br>1<br>P6<br>12<br>98<br>P7<br>16<br>37<br>Table 2<br>1) Which Scheduling Algorithm is mentioned in this question?<br>2) Write and Compile C code of Algorithm mentioned above in Linux. Also display<br>result according to Table 2.<br>3) Also draw the Gantt chart of Algorithm according to Table 2<br>4) Compute and Compare from Table 2<br>a) Waiting time for all processes<br>b) Average Waiting time<br>c) Turn Around Time for all processes<br>d) Average Turn Around Time<br>

Extracted text: Step3:Initially the waiting time of first short process as 0 and total time of first short is process the service time of that process. Step4:Calculate the total time and waiting time of remaining process. Step5:Waiting time of one process is the total time of the previous process. Step6:Total time of process is calculated by adding the waiting time and service time of each process. Step7:Total waiting time calculated by adding the waiting time of cach process. Step8:Total turnaround time calculated by adding all total time of cach process. Step9:calculate average waiting time by dividing the total waiting time by total number of process. Step10:Calculate average turnaround time by dividing the total waiting time by total number of process. Step11:Display the result according to Table 2 Process Arrival Time Burst Time P1 P2 45 P3 1 64 P4 6. 4 P5 1 P6 12 98 P7 16 37 Table 2 1) Which Scheduling Algorithm is mentioned in this question? 2) Write and Compile C code of Algorithm mentioned above in Linux. Also display result according to Table 2. 3) Also draw the Gantt chart of Algorithm according to Table 2 4) Compute and Compare from Table 2 a) Waiting time for all processes b) Average Waiting time c) Turn Around Time for all processes d) Average Turn Around Time

Jun 11, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here