Also called Decrease-key, Increase-key, Change-key and Priority update.
fresh numbers
The test's questions that a run answers, asked again on new numbers whenever you like. The answer, its working and the reason for every other choice come from changing a number in a heap's own run on the numbers shown.
choose one
1question 1
The heap drawn was made by putting in 32, 36, 52, 86, 79, 87 and 12. Then 32 changes to 95. At which place does 95 stop?
the answer, and why
the answer is B
32 stands at place 3, over 87 and 52. 95 is bigger than both, so it swaps with the smaller, 52, down to place 7, which has no child.
if you chose another
AThat swaps with 87, the first child. A sink swaps with the smaller child, 52.
CThat leaves 95 over 87 and 52, both smaller than it.
DPlace 2 is not below place 3. Place 3's children are places 6 and 7.