How you would sort a file that was too large to fit in ram

Assignment Help Basic Computer Science
Reference no: EM13951277

Consider how you would sort a file that was too large to fit in your machine's RAM. External Sorting refers to the sorting of data which is not in the primary memory of the computer. In this problem, you have to implement a miniature version of external sort. The file sizes have been intentionally kept small because of time constraints. The methodology followed has to be the same as for really big files.

a) First generate a 256 MB file Bigfile containing integers. You can make use of a random number generator, with suitable modifications on the generator output, to generate suitable integers.

b) Then sort the above file in the following manner

• Bring in 1024*1024 integers into memory at a time, and sort into an output file, thus generating 64 sorted files of integers.

• Do an 8 way merge on the contents of these files to generate 8 sorted files.

• Do a 4-way merge on the above files to generate 2 sorted files.

• Merge the two files obtained above into Bigfile, to obtain the sorted Bigfile.

Reference no: EM13951277

Questions Cloud

Context of information technology and information security : Using any of several different tools (Online White pages, Peoplefinders, Wink People Finder, etc.) someone has found your name and address. What other information would be needed in order for them to access your ONLINE bank account or credit card ..
Expected percentage change in value : 1. Calculate the duration of a $100,000 fixed-rate 30-year mortgage with a nominal annual rate of 7.0%. What is the expected percentage change in value if the required rate drops to 6.5% immediately after the mortgage is issued?
Equal sharing of monopoly output and profits : Find the critical value of the discount factor to sustain collusion if the firms play a super game and use grim punishment strategies. Assume that the collusive agreement involves equal sharing of monopoly output and profits. How does the minimum ..
Earned value to determine status : Jennifer turned in her status report for the newly approved mailing activities. She feels that her pieces are on track with nothing for you to worry about. She reports the following information for the critical path tasks:
How you would sort a file that was too large to fit in ram : Consider how you would sort a file that was too large to fit in your machine's RAM. External Sorting refers to the sorting of data which is not in the primary memory of the computer.
Different stakeholders and their interaction : The purpose of the Final Project is to apply the concepts and techniques of the module to the development of:
Legitimate reason for purchasing individual apps : Security of your data is of utmost importance to Jamie, even more so than ease of access or speed of processing. Which type of application category would you recommend Jamie use?
What is best estimate for the time till the next eruption : Write down the estimated regression equation, and verbally interpret the intercept and the slope coefficients (in terms of geysers and eruption times).
Determinants of employment inflation and value theory : Select an early and later economist and compare and contrast their theories in an important area of analysis such as the determinants of employment, inflation, value theory, development, trade, protectionism, financial crisis, or overall methodolo..

Reviews

Write a Review

Basic Computer Science Questions & Answers

  Revisiting the deployment diagram

The only thing constant in the information technology landscape is that things always change. Such is the case for the textbook ordering system you examined in the previous unit.

  What are some of the drawbacks in using passwords

what are some of the drawbacks in using passwords to limit access to a computer system?

  Write a declaration for an enumerated data type

A pet store sells dogs, cats, birds, and hamsters. Write a declaration for an enumerated data type that can represent the types of pets the store sells.

  Write recursive method prints out the digits reverse order

Write the code for a recursive method that accepts an integer argument and prints out the digits in reverse order

  Business continuity planning

Imagine that you are trying to receive funding for select planning projects. Compare and contrast the attributes of business continuity and disaster recovery plans, and suggest the primary ways in which you would explain these differences to your emp..

  Compare and contrast the in terms of cores/microprocessors

Compare and contrast the following, in terms of cores (or microprocessors), random access memory (RAM), disk storage, and networking capabilities.

  Access control system

What access control system is most valuable for protecting enterprise systems? Why? What are two specific strengths and two specific drawbacks for your chosen access control system?

  Explain standards and impact of organizations like oasis

describe the differences in these standards and impact of organizations like OASIS as a growing factor in worldwide standards setting

  Determine entities from functional requirements

Using Crow's feet, determine and draw relationships between entities. (Typically verbs in sentences will recognize these). Find out the entities from functional requirements.

  Error-detection in the data link layer

What techniques can be used for error-detection in the data link layer?

  Wikis are web-based tools that make it easy

Wikis are Web-based tools that make it easy for users to add, remove, and change online content. Employees at companies such as Intel, Motorola, IBM, and Sony use them for a host of tasks, from setting internal meeting agendas to posting docume..

  The goods are substitutes

(Substitutes and Complements) For each of the following pair of goods, determine whether the goods are substitutes, complements, or unrelated: Peanut butter and jelly, Private and public transportation, coke and pepsi, alarm clocks and automobiles, g..

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd