Math, asked by amankoli330, 11 months ago

Minimum no of comparison in min heap to find 65th smallest element

Answers

Answered by MDAyanR
0
For 11st minimum element there is maximum 00 comparison

For 22nd minimum element there is maximum 11 comparison

For 33rd minimum element there is maximum 22 comparison

For 44st minimum element there is maximum 33 comparison

...............................................................

For 6565st minimum element there is maximum 6464 comparison

So, total number of comparisons 0+1+2+...+640+1+2+...+64

64×652=2080
Similar questions