Hi guys, there's some confusions and hope to close that gap.
in the heap we have height maximum is (logn) , so if I want to calculate for example the minimum in max heap which is found on the leafs, we must go through the whole height which is logn and moreover we must also include the time that we spend on the leaf to check with minimum or not, but the professor said that the time to find minimum of the max heap is to go just on the height without including the time that we spend on the leaf itself (I mean the time for comparisons on the leaf itself with minimum .. we also do a work on the leaf so why we are not including it in calculation of time complexity?! ).. any help why we are not including the time we spend on the leaf itself for checking minimum or not?! thanks alot for your help guys.
in the heap we have height maximum is (logn) , so if I want to calculate for example the minimum in max heap which is found on the leafs, we must go through the whole height which is logn and moreover we must also include the time that we spend on the leaf to check with minimum or not, but the professor said that the time to find minimum of the max heap is to go just on the height without including the time that we spend on the leaf itself (I mean the time for comparisons on the leaf itself with minimum .. we also do a work on the leaf so why we are not including it in calculation of time complexity?! ).. any help why we are not including the time we spend on the leaf itself for checking minimum or not?! thanks alot for your help guys.