Skip to content

mwksl/LRUAlgorithm

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

To run the program, import the project into eclipse and run Main.java.

For the page amount make sure to enter a number greater than 4 or else the program will throw an error.

Sample run:
Please request the page amount: 
5
Please enter a series of 10 requests<separated by spaces>: 
1 2 3 4 5 6 7 7 8 9
+---+---+---+---+
| 1 |   |   |   | *  
+---+---+---+---+
+---+---+---+---+
| 1 | 2 |   |   | *  
+---+---+---+---+
+---+---+---+---+
| 1 | 2 | 3 |   | *  
+---+---+---+---+
+---+---+---+---+
| 1 | 2 | 3 | 4 | *  
+---+---+---+---+
+---+---+---+---+
| 5 | 2 | 3 | 4 | *  
+---+---+---+---+
+---+---+---+---+
| 5 | 6 | 3 | 4 | *  
+---+---+---+---+
+---+---+---+---+
| 5 | 6 | 7 | 4 | *  
+---+---+---+---+
+---+---+---+---+
| 5 | 6 | 7 | 4 |
+---+---+---+---+
+---+---+---+---+
| 5 | 6 | 7 | 8 | *  
+---+---+---+---+
+---+---+---+---+
| 9 | 6 | 7 | 8 | *  
+---+---+---+---+
Faults: 9

About

Implementation of an LRU paging algorithm.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages