Skip to content

phanikmr/BankersAlgorithm

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

BankersAlgorithm

Enter Total Number of Resources types:3

Enter Total Number of Processes:5

Enter MAX Number of Resources can be Allocated to P0 Process R0 resource:7

Enter MAX Number of Resources can be Allocated to P0 Process R1 resource:5

Enter MAX Number of Resources can be Allocated to P0 Process R2 resource:3

Enter MAX Number of Resources can be Allocated to P1 Process R0 resource:3

Enter MAX Number of Resources can be Allocated to P1 Process R1 resource:2

Enter MAX Number of Resources can be Allocated to P1 Process R2 resource:2

Enter MAX Number of Resources can be Allocated to P2 Process R0 resource:9

Enter MAX Number of Resources can be Allocated to P2 Process R1 resource:0

Enter MAX Number of Resources can be Allocated to P2 Process R2 resource:2

Enter MAX Number of Resources can be Allocated to P3 Process R0 resource:2

Enter MAX Number of Resources can be Allocated to P3 Process R1 resource:2

Enter MAX Number of Resources can be Allocated to P3 Process R2 resource:2

Enter MAX Number of Resources can be Allocated to P4 Process R0 resource:4

Enter MAX Number of Resources can be Allocated to P4 Process R1 resource:3

Enter MAX Number of Resources can be Allocated to P4 Process R2 resource:3

Enter Number of Resources Allocated to P0 Process R0 resource:0

Enter Number of Resources Allocated to P0 Process R1 resource:1

Enter Number of Resources Allocated to P0 Process R2 resource:0

Enter Number of Resources Allocated to P1 Process R0 resource:2

Enter Number of Resources Allocated to P1 Process R1 resource:0

Enter Number of Resources Allocated to P1 Process R2 resource:0

Enter Number of Resources Allocated to P2 Process R0 resource:3

Enter Number of Resources Allocated to P2 Process R1 resource:0

Enter Number of Resources Allocated to P2 Process R2 resource:2

Enter Number of Resources Allocated to P3 Process R0 resource:2

Enter Number of Resources Allocated to P3 Process R1 resource:1

Enter Number of Resources Allocated to P3 Process R2 resource:1

Enter Number of Resources Allocated to P4 Process R0 resource:0

Enter Number of Resources Allocated to P4 Process R1 resource:0

Enter Number of Resources Allocated to P4 Process R2 resource:2

Enter Available System Resources of type R0:3

Enter Available System Resources of type R1:3

Enter Available System Resources of type R2:2

Banker is Safe until Process P1 is Executing

Banker is Safe until Process P3 is Executing

Banker is Safe until Process P4 is Executing

Banker is Safe until Process P0 is Executing

Banker is Safe until Process P2 is Executing