Question
In this assignment you will implement the two-way external merge sort algorithm from Chapter 13 (Figure 13.1). Here are some more specifics that your program
In this assignment you will implement the two-way external merge sort algorithm from Chapter 13 (Figure 13.1). Here are some more specifics that your program should adhere to. 1. Recall that the first pass of two-way merge sort algorithm needs 1 buffer, and the subsequent passes need 3 buffer 2 for input data, and 1 for output data. 2. Assume that page size is 4KB. 3. Input buffers: Read-in the input data in chunks of 4KB (page size). Therefore, at any given point your program should read-in at most 8KB (2 pages) of input data. However, you can assume a tolerance of +/- 4bytes for each buffer to ensure that an entry (an age value) doesnt get split. 4. Output buffer: Holds at most 4KB of data, at which point the data is flushed out to the disk, specifically, to an intermediate file, or to the final file in the final pass. 5. Use the file, age.txt, which is on ilearn as an input to your program. The file contains 1 million numbers within the range [1,100] that are separated by commas. 6. Use one of the following programming language for this assignment: Java, C/C++, Python. Name your project ExternalMergeSort
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started