Q. 1 Solution:
65d91b32-5115-4161-a370-02b954666c15-image.png
Q. 2 Solution:
37b2074f-d565-4bbd-8a16-f2a87cd4fd0d-image.png
Q. 3 Solution:
2292b8a3-024d-48e4-8dfb-0a2e5b89b11f-image.png
CS702 – Advanced Algorithms Analysis and Design
Assignment 3
Instructions to Solve Assignments
The purpose of the assignments is to give students hands on practice. It is expected that students will solve assignments themselves. The Following rules that will apply during the evaluation of the assignment.
Cheating from any source will result in zero marks in the assignment.
Any student found cheating in any two of the assignments submitted during the course will
be awarded “F” grade in the course.
No assignment after the due date will be accepted.
Fall 2019
Answer the following questions in your own words. Plagiarism will be checked for each question. Marks will be awarded on the basis of the answer and plagiarism report.
Question 1 (30 Marks)
Determine the cost and structure of an optimal binary search tree (OBST) for a set of n = 5 keys with the probabilities given below. You need to calculate the tables e[i, j], w[i, j] and root[i, j].
Fall 2019
i | 0 | 1 | 2 | 3 | 4 | 5 |
---|---|---|---|---|---|---|
pi | 0.15 | 0.10 | 0.05 | 0.10 | 0.20 | |
qi | 0.05 | 0.05 | 0.05 | 0.10 | 0.05 | 0.10 |
Question 2
What is an optimal Huffman Code for the following set of frequencies? a:25 b:11 c:37 d:5 e:43 f:12 g:19 h:31
(20 Marks)
@zareen said in CS702 Assignment 3 Solution and Discussion:
Determine the cost and structure of an optimal binary search tree (OBST) for a set of n = 5 keys with the probabilities given below. You need to calculate the tables e[i, j], w[i, j] and root[i, j].
idea solution plz?