subject

Write a program to compare the performance of the lru and the optimal page replacement algorithms. the program will take a reference string and the number of frames as inputs. assume the maximum length of a reference string is 20 and there are 5 diffent pages from page 1 to page 5. the reference string can be randomly generated and the number of frames is entered through the keyboard. for example, the system generates a reference string 2 1 3 4 5 2 3 and you enter the number of frames 3. compare the number of page faults generated by the optimal and lru algorithms. print out the page replacement process and you can see how lru differs from the optimal.

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 22:20
Pp 4.1 design and implement a class called sphere that contains instance data that represents the sphere’s diameter. define the sphere constructor to accept and initialize the diameter and include getter and setter methods for the diameter. include methods that calculate and return the volume and surface area of the sphere (see pp 3.5 for the formulas). include a tostring method that returns a one-line description of the sphere. create a driver class called multisphere, whose main method instantiates and updates several sphere objects.
Answers: 1
question
Computers and Technology, 23.06.2019 03:30
Ihave a singular monitor that is a tv for my computer. recently, i took apart my computer and put it back together. when i put in the hdmi cord and booted the computer to see if it worked, the computer turned on fine but the screen was blue with "hdmi no signal." i've tried everything that doesn't require buying spare parts, any answer is appreciated!
Answers: 1
question
Computers and Technology, 23.06.2019 15:00
Jake really works well with numbers and is skilled with computers but doesn't work well with others. which of the jobs discussed in this unit might be best for jake? why?
Answers: 3
question
Computers and Technology, 23.06.2019 22:20
If i uninstall nba 2k 19 from my ps4 will my career be gone forever?
Answers: 2
You know the right answer?
Write a program to compare the performance of the lru and the optimal page replacement algorithms. t...
Questions
question
Mathematics, 17.12.2020 21:20
question
Mathematics, 17.12.2020 21:20
question
Mathematics, 17.12.2020 21:20
question
Spanish, 17.12.2020 21:20
question
Computers and Technology, 17.12.2020 21:20
Questions on the website: 13722360