www.vustudents.ning.com

We non-commercial site working hard since 2009 to facilitate learning Read More. We can't keep up without your support. Donate.

# CS502 Fundamentals of Algorithms Assignment No 02 Spring 2021 Solution / Discussion

CS502 Fundamentals of Algorithms Assignment No 02 Spring 2021 Solution / Discussion

Views: 795

### Replies to This Discussion

Share the Assignment Questions & Discuss Here....

Stay touched with this discussion, Solution idea will be uploaded as soon as possible in replies here before the due date.

Assignment No. 02
Spring 2021
CS502-
Design and Analysis of Algorithms

Total Marks: 20

Due Date: 02-06-2021

Instructions

Please read the following instructions carefully before solving & submitting assignment:

It should be clear that your assignment will not get any credit (zero marks) if:

Ø    The assignment is submitted after due date.

Ø    The submitted assignment is other than MS Word file.

Ø    The submitted assignment does NOT open or file is corrupted.

Ø    The assignment is copied (from other student or ditto copy from handouts or internet).

For clarity and simplicity, you are required to upload/submit only one .doc/docx file.

Objectives

The objectives of this assignment are;

ü  To make you familiar with Merge Sort.

ü  To make you familiar with Heap Sort.

For any query about the assignment, contact at CS502@vu.edu.pk

Good Luck!

Total Marks: 20

Question 1  (5+5 marks)

Sort the following list using Merge Sort in ascending order.

"K, N, L, D, S, D, Q, R"

It is required to draw tree structure of the merge sort procedure for both divide and combine phase separately.

Note: Finally, you will have two tree structure one for divide phase and other is for combine phase and it is also required to performed all the steps to get full marks.

Question 2 (10 marks)

For the given array, draw the final Max-Heap structure. Show a final single tree only. Steps are not required.

 43 12 23 2 55 11 7 33 60 32

Lectures Covered: Lecture No. 07 to 16.

Deadline: Your assignment must be uploaded / submitted on or before 02-06-2021.

Spring%202021_CS502_2.docx

CS502-ASSIGNMENT-N0-02-COrrect Solution file link

CS502-ASSIGNMENT-N0-02-COrrect%20Solution.docx

CS502 Assignment no 2 Solution Spring 2021

CS502 Assignment 2 Solution Spring 2021 ||Fundamentals of Algorithms|| 100% Correct Solution

#cs502 #assignment
CS502 Assigment 2 100% with solution file CS502 Assigment 2 100% with solution file

# CS502 (Fundamentals of Algorithms) Assignment No.2 Idea Solution Spring 2021

CS502-ASSIGNMENT-N0-02-COrrect Solution file link

CS502-ASSIGNMENT-N0-02-COrrect%20Solution.docx

1

2

3

4

5

## Latest Activity

Zubii joined + M.Tariq Malik's group

### MTH401 Differential Equations

4 hours ago
Zubii joined + M.Tariq Malik's group

### CS502 Fundamentals of Algorithms

4 hours ago
Zubii joined + M.Tariq Malik's group

### CS501 Advance Computer Architecture

4 hours ago
5 hours ago
5 hours ago
Batool updated their profile
6 hours ago
Terry Brown replied to irshad kausar's discussion math
7 hours ago
Terry Brown and Fahad Chaudhary joined Virtual University of Pakistan
7 hours ago