Creation of Heap, Data Structure & Algorithms

Q. Create a heap with the given list of keys:

8, 20, 9, 4, 15, 10, 7, 22, 3, 12                                                 

Ans:

Creation of the heap:- 8 20   9  4      15   10   7     22   3     12

1200_Creation of heap.png

 

Posted Date: 7/10/2012 5:44:41 AM | Location : United States







Related Discussions:- Creation of Heap, Assignment Help, Ask Question on Creation of Heap, Get Answer, Expert's Help, Creation of Heap Discussions

Write discussion on Creation of Heap
Your posts are moderated
Related Questions
The minimum cost spanning tree has broad applications in distinct fields. It represents several complicated real world problems such as: 1. Minimum distance for travelling all o

The Space - Time Trade Off The best algorithm to solve a given problem is one that needs less space in memory and takes less time to complete its implementation. But in practic

A freight train from Melbourne is approaching Sydney, carrying n cars of cargos. The cargos are to be delivered to n different cities in the metropolitan area of Sydney - one car f

Determine YIQ Colour Model Whereas an RGB monitor requires separate signals for the red, green, and blue components of an image, a television monitor uses a single composite si

what is tower of management with example

A Sort which relatively passes by a list to exchange the first element with any element less than it and then repeats with a new first element is called as      Quick sort.

Data records are stored in some particular sequence e.g., order of arrival value of key field etc. Records of sequential file cannot be randomly accessed i.e., to access the n th

Polynomials like  5x 4    +  2x 3    +  7x 2     +  10x  -  8  can  be  represented by using arrays. Arithmetic operations such as addition & multiplication of polynomials are com

A linear collection of data elements where the linear node is given by means of pointer is known as Linked list

What is complexity of an algorithm? What is the basic relation between the time and space complexities of an algorithm? Justify your answer by giving an example.