# ECET360 Week 4 Lab – Memory Allocation Simulation – With Lab Report – Perfect Solution – Instant Delivery

Lab Price = \$14
Payment methods

Problem Statement
DeVry University
ECET360 Lab 4
Memory Allocation Simulation

Name: ______________________ Date: _____________

1. Objectives
• To simulate First Fit and Best Fit memory allocation algorithms using C/C++
• To compare First Fit and Best Fit algorithms

2. Procedures
1) Simulate First Fit Memory Allocation Algorithm
We keep it simple. The number of memory partition (blocks) and size of processes are in units. The unit can be any size, say, 16 Kbytes or 64 Kbytes.
a. In this part of the program, you will:
• Prompt the user to enter the number of blocks (3 to 5)
• Prompt the user to enter the number of processes (3 to 5)
• You may prompt the user to enter block sizes and process sizes. You may also initialize them within the program.
• Implement the First Fit algorithm. Note that each process is checked against starting from the first block and gets allocated to the first block that fits it.
• When the process gets allocated, output the information on where it is placed and the remaining block size.
• See a sample output on next page.

b. Choose your own block and process sizes (keep them reasonable). Built and debug the program. Copy the source file below. (15 pts)

c. Run the program for three times using different sizes of blocks and processes. Crop the output windows (Snipping Tool is good to use) and paste them below. (6 pts)

2) Simulate Best Fit Memory Allocation Algorithm
a. In this part of the program, you will modify your last program to implement Best Fit algorithm.
To make the comparison meaningful, use the same sets of blocks and processes as the last part. The sample output is shown below:

b. Built and debug the program. Copy the source file below. (15 pts)

c. Run three same sets outputs as in first part. Paste the output windows below. (6 pts)

3. Conclusion
Compare and comments on the two memory allocation algorithms. Which one do you think perform better? Provide support. (8 pts)

Relevant Material
Screenshots
Instructions
* If you want to purchase multiple products then click on “Buy Now” button which will give you ADD TO CART option.Please note that the payment is done through PayPal.
* You can also use 2CO option if you want to purchase through Credit Cards/Paypal but make sure you put the correct billing information otherwise you wont be able to receive any download link.
* Your paypal has to be pre-loaded in order to complete the purchase or otherwise please discuss it with us at [email protected].
* All the contents are compressed in one zip folder.
* In case if you get stuck at any point during the payment process, please immediately contact us at [email protected] and we will fix it with you.
* We try our best to reach back to you on immediate basis. However, please wait for atleast 8 hours for a response from our side. Afterall, we are humans.
* Comments/Feedbacks are truely welcomed and there might be some incentives for you for the next lab/quiz/assignment.