2080 3

CSC325 ยท 2080 ยท 10 marks

Discuss heapify operation with example. Write down its algorithm and analyze its time and space complexity.

Discuss heapify operation with example. Write down its algorithm and analyze its time and space complexity.[10]

Design and Analysis of AlgorithmsChapter 3: Divide and Conquer AlgorithmsSorting Algorithms

--- A heap is a complete binary tree stored as an array where: - Max-Heap property: Every parent node is greater than or equal to its children. - Min-Heap property: Every parent node is less than or equal to its children. For an array A with 0-based indexing, for any node at index i: - Left child...