Professional Documents
Culture Documents
g Date :
{A,B, CBD, A BÌ
B D A
o
A
B 2 2
2 2 2 2
BB 2 2 3 3
24-2 2 3
(A) 2 2 4
2 2 3
Ans: BDAB
Q.2 Sz
S
1 1
b 2 2 2 2 2 2
2 2 3 3
2 2 2 3 3
2, 2 2 2 3 3
24-2 t 2 3
1 2 2 3 34-3 3 4
2 2 3 3
44-4
ASHAPURA) Ans: dcba
Ropal ECO
Date
Q2 S2 o b
S
2. 2. 2 2 2 2.
2 3 3
2
2 2 22
2. 3
3 3
3
23
2 3 4
2
4
2
ans:
bedba
@.3
2 S
2 3
d 5
2 2
d3 3 4
2 | 2 3
Bact- Toeng
cC3]= 4 C[2,7]-6 not Stre
i=3i-di= 4-4 =3
(ASHAPURA) cl3] Sare
Ropal ECO
ECoRopal (ASHAPURA)
lo t(o,o) lot ma0
C-w) k(i-4, +I0 man
45 40
37 27 3 =
37
(a 22 22 22 22 12
lo to 1
2
2
30 |2
C6 1
3 2
e43}
l4,3 S= I=2
Sare not
|-2 3
Date:
Date:
Back Toach
kC3,6]= 34 not Sgne,
2.
EC4.: 4s Er3,5J 737 not S#rne.
C= S- 273
not Sq me
3
(ASHAPURA
Ropal ECO
Date:
2.
k C4,3J<Bo ACa, 3]= 25 notSame
C= 3-3o
3 kC3
Totel aoft = 30 +S t o
Date :
A1
A2 3SxI S
A
AG
2 3 S
$750 7845 -1 9375 -3||a5.3 S|2Sr3
2 2625 -
y3ts-37(25-42S00-3
{o S -3
S35.3
Se 1
m(2,3]
mC3.4]
m(4,s ]: Sklo 20
m[24] min
ASHAPURA) 4375
Bopal ECO
Date:
mC3,5: min
mC3,43t msi s]+ Py Ps
m(4i6]: min
m4, SJr mCce]t P2 Pe P
-ol
2 3 S
3 3 3
2 2 4 3
3 3
4
(A1 A2 Ag Ay As
( Az
A3)Ay As
(AA3))_(ay As) Ac
(ASHAPURA)
Date:
ifem=s
c(w)
H| Iy
2 S
22 28
2 3
2 2 6 4
S (8 21
4 6 22 28 29
6 22 28 2 34 35
ltt(o,o ))=|
t(I,2) (o,E(e.J))=J
kCe, 2):
kC23)=
mat
t(3,S)=
t(34)=
k(3.6)= max
(ASHAPURA
30pal ECo
Eco Ropal ASHAPURA)
pdtt= Total
k(2,s) |§5)= E3,
Sqre hot
|-3
Sarl k(sI)=4o
Taciy i ack B
21
kC3,3))= f22 k(41)
lc3,3))
29 - (4,224 man
kc3/)):
29 (19,22t kcu)
22 )= D) Icc3, 22+
Date:
Explain Dijttaa'salgoaithr
Dykstaa alsoxithm
DjLstoa sed goeph toavessal ¢
patafnding algozithrm.
DËkshe Ued to find Shorest path beteen
tu nodes in a weiqhled goaph
Thisalaosith is efficient and wets taó
twell Aro finding the Shotest patth when als
negehe
Steps
A)
[2
ASHAPURA
Ropal ECo
Date:
Sousce A
A
B D
) 12
AB (6
A,B,
ABED
(6) 19
DEb,C,
Minimun Spannirg tree '
A minjmumm Spagnng
Spannin toee of a weightcd onnec led
qsoph Ck is a
Spannng
Smallet weight of edges.
ousalS
In kauskal 's algooihm, the set 4 of edyes
incseosing cadeo of tteeia lengh
Le,3]
6
I23]
(2
2
enge
Bzien's aloa1thm
In paim's algo the minmg Spanning tre
tn a natyal way sterol-ng fom gn asbitsa qaca
aot
in
Stastirg node =j
Cost edye Node
4 t3,< tl,3,)
el,6,4,3}
{s6}
3
HAPURA)
Ropal Eco
Date:
(ASHAPURA)
Ropal ECO
Date
cdiagpnals
Solutton using bact hacking i
Back Iaacking allous do betleo than this. As
Fiast dep, we aefosmulate the eight queen's problem
tyee seaschig pvblem we say that a
Vectos
paormisigg. fos osE ÇoIf none of teE queens placad
pasitian 4 VC]aUc2),(t VCK] ) thseatens
in
ang ot tte other
dag135=
then Lan 8-Pomising vec is a solutton
lwaite sof.
f Sol
etse Lexplo (ktt) romSg ertensions
b y - 1 to 8 do
beongs to col and -k does nst
if daes not
Roval eco
botorgs
ASHAPURA
Date :
then so|[ttIJe /
t solC... kt1] is K+) - paomising J
queens (kti
2
2
1
ND Slton
2.
ND
SoletiDn.
Kopal ECO
ASHAPURA)
Date:
2
B
m
S
D 6
ASHAPURA Ropal CO
wite Enuth mossis - Pratt Stsing matching algaitor
then e t
retus
ASHAPURA)
Ropal ECO
Date:
2 6
b b b
2 4
b b efloC a
2a
P2
a b a b Ca
Define.
folag
solvable in
The class P of hose pooblem tthat Qre
Consist
pDlnomial tine. That an be soued n trhe O(ok)
NP
Consiste of ho le paoblems thet qe veafiable!
Tne ctass ANP
in
paynomial tine
NP-hatd NPHdefined as
NP-hardeitten as
The class least as ha the
thot qe At
b7Dblems problen in p'
hasdest Bopal ECO
ASHAPURA)
Complete þsblem
s
to
iteducible
pynomial-
tire A
the then
NPothex all cnd NP Called pathem
is H
Conplete NPA
Date:
Date :
Lmp-mATCHER (TP)
n lengthl]
length C1
e ompufe - Prefix- Fnction [e)
num ber ot ch mtched
whileK26 and
if PCEtz] = Þl3]
thhen Ekt1
retus
ROval ECO
AAPIRA)