Question: Min Heap Add, in java 1. If the value 4 is added to the min heap below, what number will end up in the new

Min Heap Add, in java

1. If the value 4 is added to the min heap below, what number will end up in the new bottom right leaf node?

Min Heap Add, in java 1. If the value 4 is added

A. 4

B. 6

C. 12

D. 15

E. None of the above

2. How many TOTAL swaps will occur when adding the elements 6, 2, 7, 12, 5, 3, 4 (in that order) to a MAX heap?

A. 1

B. 2

C. 3

D. 4

E. 5

3. What the maximum number of swaps that could occur when building a heap with 10 items?

A. 3

B. 6

C. 10

D. 19

E. 30

6 7 12 10 14 15

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!