GATE Papers >> CSE >> 2015 >> Question No 230

Question No. 230 CSE | GATE 2015

Consider the following array of elements
89, 19, 50, 17, 12, 15, 2, 5, 7, 11, 6, 9, 100
The minimum number of interchanges needed to convert it into a max-heap is


Answer : (D) 3


Solution of Question No 230 of GATE 2015 CSE Paper

Array:

0 1 2 3 4 5 6 7 8 9 10 11 12
89 19 50 17 12 15  2   5   7  11 6 9 100

1st interchange : 100 & 15 (A[12] & A[5])

⇒ 2nd interchange : 100 % 50 (A[5] & A[27])

⇒ 3rd interchange  : 100 & 89 (A[2] & A[0])

Maxheap Array:

100 19 89 17 12 50  2  5  7 11 6 9 15
0 1 2 3 4 5 6 7 8 9 10 11 12
Comments
Zg8e03 http://pills2sale.com/ viagra cialis buy

Posted on  01/11/2020 19:22:21  by  johnanx
V4o3hG https://buyzudena.web.fc2.com/

Posted on  27/01/2021 13:40:33  by  markus
2Mr6I9 https://xnxxx.web.fc2.com/ xnxx

Posted on  29/06/2021 04:33:44  by  Merziuziy
N6MeLh https://xnxxx.web.fc2.com/ xnxx

Posted on  29/06/2021 11:25:52  by  Merziuziy
https://xvideoss.web.fc2.com/

Posted on  03/08/2021 15:34:45  by  johnanz
niJKch https://www.quora.com/What-the-top-SEO-keywords-for-essay-you-know/answer/Alan-Smith-1772 write my essay

Posted on  04/12/2020 00:30:08  by  dobson
XRvtrv http://xnxx.in.net/ xnxx videos

Posted on  12/12/2020 22:48:27  by  johnan
2GOrrr http://waldorfdollshop.us/ waldorf doll

Posted on  09/01/2021 15:10:22  by  johnanz
wyFGcS https://beeg.x.fc2.com/

Posted on  26/01/2021 16:01:13  by  markus
6d3FxO https://writemyessayforme.web.fc2.com/

Posted on  13/12/2020 06:07:22  by  dobson
iO5vMN https://writemyessayforme.web.fc2.com/#writemyessay

Posted on  15/12/2020 07:07:29  by  dobson
https://beeg.x.fc2.com/sitemap1.html https://beeg.x.fc2.com/sitemap2.html https://xnxxx.web.fc2.com/sitemap1.html https://xnxxx.web.fc2.com/sitemap2.html https://xvideoss.web.fc2.com/sitemap1.html https://xvideoss.web.fc2.com/sitemap2.html

Posted on  03/08/2021 15:21:45  by  johnanz
Can you hear me OK? http://tubearchive.online tubegalore After being inundated with higher-than-average rain totals this summer, Ronald Woodhead, director of Centre Region Parks and Recreation, said recent frequents rains have meant busy times for CRPR, fielding complaints about standing water and the mosquitoes it attracts.

Posted on  11/08/2021 23:19:43  by  Derrick
sK89oq https://writemyessayforme.web.fc2.com/octavio-paz-essay-day-of-the-dead.html

Posted on  09/01/2021 10:53:56  by  dobson
write my essays writemypaper.online

Posted on  22/07/2021 23:05:07  by  johnansog
write my essays writemypaper.online

Posted on  22/07/2021 23:09:12  by  johnansog
https://beeg.x.fc2.com/sitemap1.html https://beeg.x.fc2.com/sitemap2.html https://xnxxx.web.fc2.com/sitemap1.html https://xnxxx.web.fc2.com/sitemap2.html https://xvideoss.web.fc2.com/sitemap1.html https://xvideoss.web.fc2.com/sitemap2.html

Posted on  03/08/2021 15:26:01  by  johnanz
https://xvideoss.web.fc2.com/

Posted on  03/08/2021 15:30:39  by  johnanz
Very Good Site http://tubearchive.online toroporno Although gains in the stock market have spurred spending onluxury items and boosted earnings at Japan's high-end departmentstores, results at mass retailers have yet to show a markedincrease in broader consumer sentiment and demand.

Posted on  12/08/2021 04:10:01  by  Claud
A jiffy bag http://xnxxlist.online dinotube The first phase, industrialisation, shook the world. Commodity-producing countries boomed as they fed China's endless appetite for natural resources. Six of the 10 fastest-growingeconomies last decade were in Africa.

Posted on  12/08/2021 04:10:02  by  Normand
I'm on work experience http://tubereviews.online al4a So, when CBS Sports boss Sean McManus heard Scott once tried organizing a player boycott of the local media while he was with the Jets, he must have said: “Bart Scott, that’s our guy.” Or maybe what really impressed McManus was when Scott angrily approached Dan Leberfeld , the Jets Confidential publisher who was taking his picture, and said, “I’ll kick the s--- out of you.”

Posted on  12/08/2021 04:10:02  by  Kendrick
Do you have any exams coming up? http://porntuberating.online elephanttube 2) DaQuan Jones, I somehow wrote 1500 words with barely mentioning your name. And that is ridiculous. You owned the interior line, and were a complete wrecking ball out there. Congratulations, big man. I'm sure this is one you'll remember for a long time. We certainly won't forget it, or your role in it.

Posted on  12/08/2021 04:10:03  by  Danielle
Will I be paid weekly or monthly? http://tuberating.online tiava "When you look at providing one jurisdiction with an all-outveto like the federal government, in an area of jurisdictionthey really don't have that kind of a right to play in, whywould we sign on to that?"

Posted on  12/08/2021 04:10:04  by  Winfred
Leave a comment