retagged by
2,428 views
1 votes
1 votes

The elements $42, 25, 30, 40, 22, 35, 26$ are inserted one by one in the given order into a max-heap. The resultant max-heap is sorted in an array implementation as

  1. $<42, 40, 35, 25, 22, 30, 26>$
  2. $<42, 35, 40, 22, 25, 30, 26>$
  3. $<42, 40, 35, 25, 22, 26, 30>$
  4. $<42, 35, 40, 22, 25, 26, 30>$
retagged by

1 Answer

Related questions

0 votes
0 votes
1 answer
1
Arjun asked Jan 2, 2019
17,126 views
Consider the following postfix expression with single digit operands :$6 \; 2 \: 3 \: ^* \: / \: 4 \: 2 \: ^* \; + \: 6 \: 8 \: ^* \: -$The top two elements of the stack...
0 votes
0 votes
2 answers
2
Arjun asked Jan 2, 2019
5,838 views
A binary search tree is constructed by inserting the following numbers in order :$60, 25, 72, 15, 30, 68, 101, 13, 18, 47, 70, 34$The number of nodes in the left subtree ...
1 votes
1 votes
2 answers
3
Arjun asked Jan 2, 2019
2,886 views
Consider a singly linked list. What is the worst case time complexity of the best-known algorithm to delete the node $a$, pointer to this node is $q$, from the list?$O(n ...
1 votes
1 votes
3 answers
4
Pooja Khatri asked Jul 13, 2018
3,427 views
Consider the array A=<4, 1, 3, 2, 16, 9, 10, 14, 8, 7>. After building heap from the array A, the depth of the heap and the right child of max-heap are ______ and _____ r...