Lines Matching full:smallest
26 smallest element is always the root, ``heap[0]``.
31 since Python uses zero-based indexing. (b) Our pop method returns the smallest
36 surprises: ``heap[0]`` is the smallest item, and ``heap.sort()`` maintains the
52 Pop and return the smallest item from the *heap*, maintaining the heap
54 smallest item without popping it, use ``heap[0]``.
59 Push *item* on the heap, then pop and return the smallest item from the
71 Pop and return the smallest item from the *heap*, and also push the new *item*.
96 streams is already sorted (smallest to largest).
107 be sorted from largest to smallest.
124 Return a list with the *n* smallest elements from the dataset defined by
141 pushing all values onto a heap and then popping off the smallest values one at a
246 that ``a[0]`` is always its smallest element.
281 means the smallest scheduled time. When an event schedules other events for