Home » Programming & Data Structure » Programming and data structure miscellaneous » Question

Programming and data structure miscellaneous

Programming & Data Structure

  1. Consider a max heap, represented by the array: 40, 30, 20, 10, 15, 16, 17, 8, 4.

    Now consider that a value 35 is inserted into this heap. After insertion, the new heap is
    1. 40, 30, 20, 10, 15, 16, 17, 8, 4, 35
    2. 40, 35, 20, 10, 30, 16, 17, 8, 4, 15
    3. 40, 30, 20, 10, 35, 16, 17, 8, 4, 15
    4. 40, 35, 20, 10, 15, 16, 17, 8, 4, 30
Correct Option: B







Your comments will be displayed only after manual approval.