Professional Documents
Culture Documents
Tutorial no:5
Probiem solunq on Dynarte prcqraming
=5kg n=4
5 w (2,3, 4,5)
Pi (3, 4,5,6)
Sve
W->
problem using 0l knapsack
|I2
2 33
2. |O3 3 3
3 2 4464|7
4| 5 7
5 4 O o3 457
7 3
30
A B
4xlo (Ox3 3x12
MCI,]-0
Ml2,2.]-0
M[3,3]=0
2
1 o 120 264
10 2 360
M21 MI31
ABC
15 4x103 ACBC) CAB) c
j20
MLI tM[Z,3)
=84D
M[2,3I
20 iox3 8x)2 (AB)
iOx3x2 MI2]+ M[3,31
F36O |2Ot Ot yx3x )2
|20+l44
=264
25
30
|CarnlinPage
Date
Si b.a. b
le2 2 2
d (4 24| 22<
222k2
10 |a3
3<
24|2<34 length of common
142^2< Subsequence=y
b a C e' the
is the
e is qest
longest co mmOn
Sub sequunc!
15