Professional Documents
Culture Documents
6 7
4
3
3
7 10 8
4
5 6
9
QNo 2.
9 3
e d
2
QNo 3.
Solve the following instance of Knapsack
problem, using greedy algorithm :
Knapsack weight M = 5
Item 1 2 3 4
Weight 2 1 3 2
Profit 120 150 200 150
QNo 4.
Character A B C D E
Probability 0.2 0.15 0.1 0.2 0.35
QNo 6.
a g
c
f
d
QNo 8.
Determine the shortest distances from
source vertex 5 to all the remaining
vertices using Dijikstra’s algorithm.
45
4
0
20
15
1
35
20 15
10 30
10
5
2 3
20 4
QNo 9.