Example 1: c program to implement non preemptive priority scheduling algorithm # include <stdio.h> int main ( ) { int bt [ 20 ] , p [ 20 ] , wt [ 20 ] , tat [ 20 ] , pr [ 20 ] , i , j , n , total = 0 , pos , temp , avg_wt , avg_tat ; printf ( "Enter Total Number of Process:" ) ; scanf ( "%d" , & n ) ; printf ( "\nEnter Burst Time and Priority\n" ) ; for ( i = 0 ; i < n ; i ++ ) { printf ( "\nP[%d]\n" , i + 1 ) ; printf ( "Burst Time:" ) ; scanf ( "%d" , & bt [ i ] ) ; printf ( "Priority:" ) ; scanf ( "%d" , & 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 ; i < n ; i ++ ) { pos = i ; for ( j = i + 1 ; j < n ; j ++ ) ...