Where in the heap largest element resider

Assignment Help Chemistry
Reference no: EM131016659

Algorithms

1. Assume you have a max heap.

     Q1) Where in the heap largest element reside?

     Q2) Where in the heap smallest element reside?

2. Draw heap for the following array

    A = {23,17,14,6,13,10,1,5,7,12}

    Q1) Is this a max heap?

    Q2) Is this a min heap?

3. Suppose A is an array sorted in decreasing order.

    Is array A a max heap or min heap?

4. Construct max heap for

    A = {2, 20,25,4,8,5,7,13,17}

     1. Using top bottom construction

     2. Using bottom up construction

5. For the heap constructed in Question 4

     1. Illustrate the operation of HEAP SORT

 

6. Draw min heap for

    A = {15,13,9,5,12,8,7,4,0,9,2,1} ;

    1. Now insert 3 to the heap.

    2. Delete top of the heap and show the

        heap after deletion

Reference no: EM131016659

Questions Cloud

Find ways to enhance market power by pooling and negotiating : Find economies of scope. Provide examples of specific actions Harley-Davidson's managers could take to reduce expenses or share activities through horizontal relationships across brands.
What are some books that include excel exercises : What are some books that include excel exercises on the accounting cycle?
What characteristics makes them crimes of public order : Please Explain 4 seperate times What are some of the crimes of public order? What characteristics makes them crimes of public order
What are the characteristics of a recursive algorithm : What are the characteristics of a recursive algorithm in 8086 assembly language?
Where in the heap largest element resider : 1. Assume you have a max heap.      Q1) Where in the heap largest element reside?      Q2) Where in the heap smallest element reside?
The following events took place for video wave : The following events took place for Video Wave Manufacturing Company during January 2016, the first month of its operations as a producer of digital video monitors:
Explain why you agree or disagree with your results : How can you use goal-setting to increase motivation and improve job performance?
How creating a website can influence the social awareness : My homework is to write an essay about how creating a website can influence the social awareness and fundraising abilities of Lutheran Social Services in Thousand Oaks. Lutheran Social Services is an nonprofit organization
Qualitative data analysis for three nvivo tutorials : In about 750 words, write an analysis report, including the following: The applications of qualitative data analysis for three NVivo tutorials. The content of examples, and how this might apply to the chosen topic of your interest and qualitative met..

Reviews

Write a Review

Chemistry Questions & Answers

  The elimination on treatment with sodium ethoxide in ethanol

which one of the following alkyl halides gives the highest ratio of substitution to elimination on treatment with sodium ethoxide in ethanol, and why?

  Explain solution is to create the greatest osmotic pull

Explain which of these intravenous solutions would cause the greatest increase in blood volume by osmotically drawing water into the blood vessels? Explain which solution is going to create the greatest osmotic pull.

  Explain determination of aspirin in commercial preparations

suggest a procedure you could follow to determine whether it was necessary to use this solution as a reference or whether distilled water would have been just as satifactory

  State a balanced chemical equation for the bomb calorimeter

A 1.80-g sample of phenol (C6H5OH) was burn up in a bomb calorimeter whose total heat capacity is 11.66 kJ/°C. The temperature of the calorimeter plus contents improved from 21.36°C to 26.37°C. State a balanced chemical equation for the bomb calor..

  Compute the equilibrium concentration of oh-

If the equilibrium concentration of Cd2+ ion is 1.5 X 10-6 M, calculate the equilibrium concentration of OH- in an aqueous equilibrium between solid Cd(OH)2 and its ions. (Ksp for Cd(OH)2 is 2.5 X 10-14)

  What is the partial pressure of oxygen in the mixture

a gasous mixture of oxygen and nitrogen contains 32.8% nitrogen by mass. what is the partial pressure of oxygen in the mixture if the total pressure is 405mmHG?

  Energy of electron

The energy of electron of wavelength 0.3 nm in Joules and electron volts

  How to calculate the solubility

The Ksp of CaSO4 is 4.93× 10-5. Calculate the solubility (in g/L) of CaSO4(s) in 0.300 M Na2SO4(aq) at 25 °C.

  A 1000-g sample of water at 270 oc is poured into a 750-g

a 100.0-g sample of water at 27.0 oc is poured into a 75.0-g sample of water at 89.0 oc. what will be the final

  Explain why do br and i interfere with the no

Why do Br And I interfere with the NO3 test? Explain fully using bromide as an example, including equations. 3. Explain why an excess of Fe2+ is necessary for the NO3 test.

  How to calculate the ph of a solution formed by mixing

Calculate the pH of a solution formed by mixing 10.0 mL of 0.100 M HBr with 20.0 mL of 0.200 M HCl.

  What is the percent abundance of the lower-mass isotope

If a random sample of this element collected from the tail of a comet has an weighted average atomic mass of 10.788 amu, what is the percent abundance of the lower-mass isotope?

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