1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Sedbober [7]
3 years ago
15

Assuming that a query has a buffer holding up to 3 blocks, and each block can hold two records. Use merge-sort to sort the follo

wing records in ascending order: 10, 11, 1, 5, 90, 1, 2, 101
How many runs will be produced in the whole algorithm and what are the contents of the runs?
Engineering
1 answer:
kipiarov [429]3 years ago
5 0

Answer:

a) 5 runs will be generated.

b) Since the buffer can hold 3 records, the first 3 runs are (1, 10, 11), (1, 5, 90) and (2, 10). Then we need to reserve one block as output buffer, the algorithm can merge two runs at most at the same time. As a result, we can choose to merge the first two runs into a larger one: (1,1,5,10,11,90), which is merged with the run (2, 10) to generate the final output.

Explanation:

5 runs will be generated.

Since the buffer can hold 3 records, the first 3 runs are (1, 10, 11), (1, 5, 90) and (2, 10). Then we need to reserve one block as output buffer, the algorithm can merge two runs at most at the same time. As a result, we can choose to merge the first two runs into a larger one: (1,1,5,10,11,90), which is merged with the run (2, 10) to generate the final output.

You might be interested in
Establishes general guidelines concerning licensing and vehicle
gavmur [86]

Answer:

A. National Highway Safety Act

Explanation:

The National Highway Safety Act establishes general guidelines concerning licensing, vehicle registration and inspection, and traffic laws for state regulations. The act was made in 1966 to reduce the amount of death on the highway as a result of increase in deaths by 30% between 1960 and 1965

National Traffic and Motor Vehicle Safety Act regulates vehicle manufacturers  by ensuring national safety standards and issuance recalls for defective vehicles

Uniform Traffic Control Devices Act  defines shapes, colors and locations for road signs, traffic signals, and road markings

5 0
3 years ago
Read 2 more answers
A steel bar 110 mm long and having a square cross section 22 mm on an edge is pulled in tension with a load of 89,000 N, and exp
iragen [17]

Answer:

Elastic modulus of steel  = 202.27 GPa

Explanation:

given data

long = 110 mm = 0.11 m

cross section 22 mm  = 0.022 m

load = 89,000 N

elongation = 0.10 mm = 1 × 10^{-4} m

solution

we know that Elastic modulus is express as

Elastic modulus = \frac{stress}{strain}    ................1

here stress is

Stress = \frac{Force}{area}       .................2

Area = (0.022)²

and  

Strain = \frac{extension}{length}       .............3

so here put value in equation 1 we get

Elastic modulus = \frac{89,000\times 0.11}{0.022^2 \times 1 \times 10^{-4} }  

Elastic modulus of steel = 202.27 × 10^9 Pa

Elastic modulus of steel  = 202.27 GPa

3 0
3 years ago
What is the purpose of O-ring and valve seals in a cylinder head?
Andrews [41]

Answer:

its to show the shape is flat and only flat at the botom and top and you can set it up ther way and it wlll still look the same.

Explanation:

8 0
3 years ago
Describe the cycle that purifies drinking water. 40 points
Sunny_sXe [5.5K]
Umm the Water cycle sorry I’m trying
5 0
3 years ago
Read 2 more answers
Does the Diesel engine have engine knock or detonation problem? Why?
Luda [366]

Explanation:

Yes Diesel engine have problem of knocking.

We know that knocking is phenomenon in which suddenly large amount of power generates this large amount of power will cause the failure of diesel engine.

Actually when one set of fuel inject inside the cylinder to burn with already compressed air (in general up to 10-15 bar) then this fuel does not burn complete and accumulate inside the cylinder.After that second set of fuel inject inside the cylinder then that one set of fuel burns with second set of fuel and produces large amount of sudden power for engine and causes the breaks in the crank or connecting rod of engine.it leads to damage the engine.

6 0
3 years ago
Other questions:
  • How to build a laser pointer?
    12·1 answer
  • Please answer question #2
    6·1 answer
  • A pressure gage at the inlet to a gas compressor indicates that the gage pressure is 40.0 kPa. Atmospheric pressure is 1.01 bar.
    5·1 answer
  • A hollow, spherical shell with mass 2.00kg rolls without slipping down a slope angled at 38.0?.
    15·1 answer
  • A minor road intersects a major 4-lane divided road with a design speed of 50 mph and a median width of 12 ft. The intersection
    13·1 answer
  • Users say that the game is interesting to look at but the music gets annoying
    9·1 answer
  • ¿Cómo nos podría ayudar una hoja de cálculo en nuestro estudio?
    11·1 answer
  • 3. How can statistical analysis of a dataset inform a design process?<br> PLEASE I NEED THIS ANSWER
    8·1 answer
  • Write a Nested While Loop that will increment the '*' from 1 to 10.
    6·1 answer
  • In python, how would I randomize numbers and insert them into a file?
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!