Data Structures (CS301)
Assignment # 4(Graded)
Total marks = 20
Deadline Date = 02/02/2016
Please carefully read the following instructions before attempting assignment.
Rules for Marking
It should be clear that your assignment would not get any credit if:
1) You should concern recommended books to clarify your concepts as handouts are not sufficient.
2) You are supposed to submit your assignment in .cpp format. Any other formats like scan images,doc, PDF, zip, rar, bmp etc will not be accepted.
No assignment will be accepted after the due date via email in any case (whether it is the case of load shedding or internet malfunctioning etc.). Hence refrain from uploading assignment in the last hour of deadline. It is recommended to upload solution file at least two days before its closing date.
For any query, feel free to email at:
Suppose we want to develop software for token machine of ABC bank. At entrance, token machine generates token for each customer. The first 10 customers received the following token numbers:
00, 11, 22, 33, 44, 55, 66, 77, 88 and 99
Students are required to write C++ code in order to:
Your solution should contain the following functions:
buildMaxHeap() function is used to build MaxHeap.
buildMinHeap() function is used to build MinHeap.
maxHeapify() function is used to arrange the values according to the max heap property.
minHeapify() function is used to arrange the values according to the min heap property.
In main() function, declare an array of 10 elements of integer type. Assign the values as given in the sample output.
Then call the buildMaxHeap() function and print the max heap values as given in the sample output.
Then call the buildMinHeap() function and print the min heap values as given in the sample output.
Best of luck!
+ http://bit.ly/vucodes (Link for Assignments, GDBs & Online Quizzes Solution)
+ http://bit.ly/papersvu (Link for Past Papers, Solved MCQs, Short Notes & More)+ Click Here to Search (Looking For something at vustudents.ning.com?) + Click Here To Join (Our facebook study Group)
Output of the Assignment
Ash kero sub right solution is here........
dear umer zunair this is not fulfill the assignment output.
its has some error coz when u press any key after execution of prog its ouput disappears
A.o.A as code me earr hai please bhi g send the complete correct code ak din rha ga hai plz help ker do
i respect u,r participation but i cant see any object orientation or class , Heep is implement through class in handouts, i think u have to implement via class & dynamic array. refer to lecture #31 for idea.
i have jsut make this for idea.... please you have to change its output according to the sample output.
rather everything is ok in my solution file......