Professional Documents
Culture Documents
It=:::=COMPUTER
-.- SCIENCE & ENGINEERING
B Quick Son
SEcnON·A C Minimum I'Ctght Sjlannong tree
This question conulins 10 subparts, each D. Connected Components
cat•ryin.g I mou·k. Each subJUU1 routains a LisrlJ
multiple cltoice qu~tion. \VIite in youo· nnsw.,o· I Greedy
book the subpar1 numbet· and !be leUe~· A, B, C 2. Depth- First Senrcl1
o,. n corresponlling to the most a ppt·opliate 3. Dynamic l'rogmmming
answer·. ~. Dh•ide and Conquer
(Marks: 10 x I = 10) Codes;
/\ 13 c D
The probabi hly tllat it 1\111 rain loda) is a. 2 4 I 3
0 5. Tile probability lhal it 1\ m rain b. 3 4 I 2
tomorro\\ 1s 0.6 The probability thnt it c. 3 -1 2 I
" i.U min either tod~ or tomorrow is 0,7 d 4 I 2 3
What is th~ probabilit) 1h:u it \\ill r:u•• (i In ~~• follo11·1ng grammur
today wtd tomorrow? X : : •XfBYIY
a 0.3
b () '25 y :: - Z 0YIZ
c. 0.35
II o,.J z :: ·id
2. The Ne\\1on-'Raphson oneU10d 1s used to Which of !11e followUlg is true?
find the root of th~ equation ,..J - 1 = tl. II a •e- is left. associative \l hile ~' 1s
the Iterations are starled from - 1. the righl assodati ve
itera11ons will b. Bolb -e· and •j;i· are le11. assoc13dve
a converge to -I c. -Ell - 1s roght nssOclath'e \\'hde -EJ· ts
b, con' erge to ../2 left associatl\·e
d None of the above
c C()ll\•erge 10 - ../2
7 Wl1tch ol tile. f0IJOMny IS essennal for
d. not com erga
converting an iunx expression to the
3. The delem1inru11of the 1113LIJX
_g postfiX form efficiently'/
I I
n. An operator stack
r: u 0
(J
2
()
-1
-1II
0 -I
li b An operand stack
c. A n operand stack tllld ·m1 ope•ntor sl:1ck
d. A par.;e tree
A language L allows declam11011 of arril) s
IS whose sizes 11re not known during
a. I I compilatiO!l 11 is rcquued to m:tl.e
b -~S efficient use of memO!)' Which one of the
c ()
following 1s true'/
tl -24 a A compiler usi ng static memory
4. The concatenation of two lists is t<l be allocation can be writlen for L
pcrfonued in 0 (1 )'time. Which of tbe b A compiler Clll100t be "nuen ro,· L an
a, singly li nbed list interpreter must he used
b doubly linked list c. A compiler us1ng dynnnuc memory
c. c1rculnr doubly linked lisL allocanon can be written lor L
cL urra" 11rtpleonen1.111on oflist d. None of the above
s. The co'rrocl matching for the following 'I The cond.iuonal e.xpans10n fQdihy or
poirs IS macro processors i:s provided lo
Llsll a. test n condition d.uring, the execuuon of
A All poirs shortest paths the expanded progtam
lo1 IZ
b. 10 e.\"f>aruJ -.:at.ain model SIUJem~uts 2. Disk
de~ndin& upon !be v;tlue ~f • 3, Printer
QOndition during ll1.: e~~:Nulioo of dt< 4. ALU
cxpandtd program c,, d~:
2
B
J
I
c
I
J
2
4
D
b. !\ (JO X L- 10)
..:.. 0
<l 1 l(>. Let (Z.*) be. ~~~ nlg~brat" struclu~ wber~
12. RS1' 7.5 iJtlcn"pt iJt ~0~5 uiic'rltrr,wes•or Z rs tb.e. sol of integers :tnd the oper.1tion •
<l(l:l:ut<R Ute lul<rrupl ~erviu~ nwtirte rm111 is <lefined by n•ru= maxunPot{n.m).
interrupt \'oetl;)r h>talinn \\1tich Qf the following slat.:ments Is lrue
:L O!!OOH fllr cz.•)?
b. 0075H a. (7. ') i~ u monoid
u. 003Cil b. (7- 11 ) is :UJ Abel inn grouf1
d. OOJ4H .:. (7. • ) rs u gruup
Purpos~ uf a stan bit in R8232 •~rilrl d,. Non~ or tho nh<IVO
C()Jtimunicotion prol&.'OI is. 17. Wluch of tbc fo lJmvl.ng pro[>f'sit il'flll is n
,,, In !.\·ynchronji!1i rr:c¢h~r lhr re..:eiving tnuto!Qgy?
cv.:ry 1))1c :L (pvq)-+f'
h1 to ~)rJ·ichrqnie:s l'l:Cc:iVttr ror I>Cedving U b. pv(q4fl)
><'Jli<I!C< tlf byt05
~. • ,purity bit ..-. pv(p ->tf)
d. hl t$1~hroulo:S r·.:.:~iv« tor N,.._>J.vi~~g
d- P_.(p-+q )
the lust byte
14. l11~ COITt<ll m :U d1iog for ~1.: jO.,Jiowfug 1~. lo the l~ltioc defined by the Hnsse dlugram
gjv~n in Fig 3, 3, how mJtny complemeniS
pai111 is
ooes tho d<tmlll ' c. bnve't
List I
A. DM•..I, JIO a
Fl Cuche
C lnlcmJptllt)
U. C'orrditioo Code Register
Lisl ll
L ll1sb $JlCCd RAM
:ctr
•• 1
r
~ uf 12
b, 3 d m•Y cltonge $Uite of interrupted
c. 0 process to ·~lo~ktjj' and schedule
<L I another pi'CicCss
19. Givrm I: ~ Ill. b). 11hicl1 one of the 24. Titroshins
following ~cts ih not ~ount~ble'l "· reduce;; J»Sd 110
~. Se1 of all string• over t h. dt:CfeMe.. th~ do:grt:e of
or
b. Set. ~lllonguoges OY... $ IUUitipiOgr.tmm iug
c, Set of all reiular langllllgtS ove1 ~ c:. implies CJ(o!e!Joivc poge 110
d. Set of oU l•ngullJ!"" ow:r 1: ncc=oJltc-d by d. improv~ Ihe <ystem p<llfomi:lnce
Turing mochiu>'S 25. Dirty hit for a page in o page tahk
a. help> • void unuccessllr,\ 11 rite>; uu ~
20. Locality of reference impli<:~< that the page
n-fcrcnce beirt~ made bV ~ proces~ paging device
" · 11 ill all\ ays Jlu tl) lhe page u.~od '" Ute
h. help< mnin(nin l,Rt J informntiun
preVious PJige relcrcnce c. niJows o~ ly re:ul on • Jl"S»
h, i~ likely to be to (>ne of the pnges u•ed d. non~ m~1e above:
in tho l>$t Cow page refc:rence$
"-. will •lwoyK be to one •Jr the pag"' l'his <JOOSt ion contuins 10 so bpart<. cnch
~ ting in mt'tnory carrr lng '2 mnrks. Each subpiU't rontnios a
d. will alway> rood Inn JIOl!e limh muJti ple,tt choir" quesHoo. \Vritt:! in vuu.c aornV('r
Zl. rlie <XJ[rc<:l nJ"lching fo•· tbe fo llowing book the subpart oumb<.r mullbo l~tlcy A. B. C
pairs u or 0 corresponding lo lhc n1ost anproprial•
l.istl
A. Disk scheduling
.B• .Botcb pro.:essing
C. Time shnrine 26. What ts Ute maximum nlue of dte
D, Interrupt pr~ing r
func.tivn (.X J=.4" - lr-t (> io the tntt:rVlll
List II IO, 217
1.. 1tound robin 3, 6
2. SCAN b. 10
.1. UFO c. l2
4. FIFO d. S.5
Codes: 27. l.et A = ( fiij) be an n-rO\\ed square matri\
.\ il c D and r,l be the molri.~ f1btainod by
"· J 4 2 1 int.,rcl••nging tbc 11,.,1 """ second tow• or
I>. 4 3 2 J the n-rowed ldenti~y mntri-'\. 111en Al 1: i~
c.. 2 + 1 3 •uch thhl il~ tiA<t
cl 3 -l 2 ~ roll i1 Ut c$ame ._, il< ~oeond ro"
22. vo redirection b. row i< tb ¢ same M11le second rOW of 4
u. impli<!!! cll~ngms the namu or"' IIJ;, c. t (liumn is the sa me :l!l the o;eeond
b. """ be cmpluycd to u.~c "" oxl<ting lllc eolunut of A
liM input Gle for •t J
lrogram d. row is aU ~=
c impliet; connecting 2 progmm~ through ;!8. Using Uto fonvord 1Iuler rue\hod 10 solve
a 11ipc y "(I) : J (II.y(O) = Owitb ~ 1tep size of
tL none of the •bove
\Vhen 411 Tnterrupt occu..-, lm operatin& It. we obloin U1c following volu~ of y in
Um firstfour iternlion.:
iYSlem
u. ignon:::l lhe int<.Tl'upl "· tl. /if'(O). !t(f(O)-t J (/l))and
b. nlw•y5 chJlugt:. • t11Le of iutcr1'uplcd 1!(.1'(11)-/(f,} -t f (2h))
proceM !Q 'l>lncked' nnd •ch~dulc.
3nothcr pmet:ss h, O,tl./lf/(11) •n•l 211 1; (0) , J( h)
c, alw~ys .-..ume5 cx«:ulion of c. O.tl.lr' (( n)cmd31r'f(O)
interrupted process nllcr ptoe<.lssiug the
d, 0.0, 11/'(0) 1 lt'J(O)nnd
interrupt
IV (01- h' /(0) - lif(/1)
-1 oil:.'
29. A polytlomiol p(x) I• •uc:Jt lhnt p(O) = 5,
p(l ) -1. p(:!) 9 and p(3) 20. 'Ill~
minimum dcgree.Jtcmn hn\•c i$ I : illlqcr ;
0. .,
h. 2 Sl
0'. :t l:llll. c ;
d. 4
~0. A bmaey '"""'b tree QOtltnirul U1e volu\:!1 t. end A;
2. 3. 4, 5. 6. 7. 8, 'Tho ln-.. is trnv~'T!cd In The vuri•blcs ~""Ol<l>ible u1 SJ and S2 ""'
pre-order llnd the vnln"" nre printed out. a. 11 ofA. ) ••~ ofB aod.z in SJ and
Which of H1e foiiQ'ving sequences IS 11 x of B. y nnduu S2
vnlid output? b. x of B. y nodz in Sl nod
a. 5312.1786 " of B. i and z in S2
b. 53126487 c. x of B. l. andy in S l and
"· 532-l t67S x or A. i u.od in S2
,1. 5312.176~ d. None of lhe nbovc
~t. t.et l'(n) be the function deiined hy 34. The CKpl"s~1on (n•b)~ o op .....
T(l) • l.T (t•)- 2T(l nl2j)+ v'il for whc:ro ·op' is ona of ·+·. ·•· nnd ·1"
" ? 2 . \V111cJt o f lh~ following glu(cmcnU! (oxp<ll)entintion) coo he evaluated on o
i~ uue2 CPl with A single regi.<ter without , l.oring
l11e value of (o"' b) if
"' T(n) =0( .Jn) a. •.,p· ;~· 'i ·or ·•·
h. r(n )=Oi n) b. 'np· is •T· or._..
c. ·op"is'l 'or-·"-'
"- T(n )= O!Logll) 'l nul IX"'$ihl~ to evl\lu111e \\'ilho\11 •tortng
<l N(!lle of th" ahllVc: .;s. rrw tn•pe7.oicL1I method lo numerioally
32, A priorily IJUC:Uc Q is used to it11ph:menl•• •
obtain J.f(-<) dx hos on error E bounded
stnok S thnl >101'<:> chlllWlm. PUSH (C) i.
implcruJcnted os L'ISERT (Q. C. K) whore •
K is nn approp<inle intogcr L:"Cy chOlien by
the implementnlion. POP is implemented
by 12'" mW< ["(.r).<e l.r,bJ
b-<1
"~ OELm'EMIN (Q), For o se<tucncc or where h IS the w1dth oflhe tmpe-A'lids. t he
opc:.rutions, the kcy.s chQ!.'tn •n: in minimum numh<roftmpcZoids guanmlecd
1
"- Non-jnc=s-ul{! ortlor to enstii'C E S I() in computmg In 7 us •ng
b. Non-~lng or<kir I .
c. strictly incruasin,g order f .r :: - iS,
b. SOH d.
D. 5011 4l Let G ha: :a .groph wilh I00 verliees
d. :!2 H numb<:rcd I 1<1 IQ\1. TwQ vertic"-' i ontl j
38, A nucro inuruction intfl be d""igned to It-
are ndjuccnl iJr 11: Mfll ' 1•-tl:
n . 11te.
~pecify numt>.:r of connected eompcmenl~ in G t•
(b) non~ or one of lhe lhrec mioro a. R
oper01tioM of one kind and b. 4
(h ) none or upto si.~ mkm operation~ c. 1:!
uf ono~u:r kind d.. :3
The minimum uumboe.· of bits .in Ote .uticro- -1~. The numl>er or equivalen.,.; relation~ on
inMnaction is lhe •et [1, 2.3. 4} t~
a !) n. 15
b. 5 h. 16
.). 8 CJ 2 ..
d. none vr ilte obov~ d. -1
>9 Given J n4), • 13),. ·14. \VhiOh one of the foUo1ving rcgulut
The va lue nPUac rnd~ r is: expression~ over {0. I} denotes d>e "'"' of
(L til aU <trittgs n11l containing l(l(J as a
h. ~ sub.striJ>g?
c, 5 a. o•p'O)*
d. 6 b. tl* IOlO•
~0 Consider Ute lo&io oireuia sho" n in fig. c. 0• 1 ~0 1 *
5.5. ·n,e
function~Jt.Ji 1111dj (an canonical d. 0•(1011)'
~um of pi'Ciducls lbnu in decim:al nolalioul -IS. Wbiob one of tbe foUow(ug i~ nut
lilt dcoidable1
,, ~. Given a turning maobane M o ·string s
" --Dr.,====D>-=-'-
and an integer k. M """'"PL s wiU1ln k
,A•I _ _ __. steps
b. r!qoivalenae of lwo gh••'Tl ruming
J; (II',X,J' 7)• ~ &,9.10 mach met;
}~( tr, ,~:,y. 7 )~ ~ 7,8, 1.!, I ~. 14, 1S c. Language aa:cepteid by a given finite
>Idle macllind U. non empty'
J'( .....~.)'.%)= ~ 7.9 <1. Language generated b) a urmlel(l fn:e
fhe functlon/1 is gptmmt1r il'i non. empty
n. I:9. ltl 46. Which of U1e following language$ •11't:r (u.
b. !Q ~. cl i.s a.:oq>ted b) det.,nninJ!tic
c~ ~l8. 9 pu.•hdown nutu mom1
cL l: 8. lO. IS =
a. {w w•l w eqa.bj•}
NQte· ,,. i~ th~ .'>triug !'blllfneJ b) a. None of ( I ). (2). (3) ur (4) M n onu!lc it>
rc\'CTNing. ·w·, l'iulation
47 /In apcraling :;ySiom cl)ntains 3 user b. All uf ( I ~ (2). (3) uncJ (4) cuu cullse ot~
pmces.<es each roquirin11 2 uniiS ot' violjJJjon
1'\lS(Iurce R 'nto minimum numbilr of unitW e. Both ( l) aml (4) can causa itl1 violatiQn
"f R such thnt no deadlocks \\ill ever nnso d. Bo!lt t2) uuJ (.3) can cause ilsviolatiQn
is 5l AD llfp-llop is I(> be connected ''~ au 8085
8; J mil.1l)proces~r dill' us u l·l:ii t Output [l(Jn
b. 5 witlr a pon. address ot' FF h<;X. Dlllll bit 0,
o. " should be ini'OI\'od in the .datu Irunsfcr
d. 6 frvm CPU to the llip-Ootl. rlt• lllp-llop
48. l:.aoh process l'f+ 1 - J ... JJ IS coded as should be ole.ute.d on powor ON,
fi>llows a. Usin~ 11nly one NAND ~lllc (Ian in of
repeal 10). one NOT gate and <Jne l) Uip-tlop.
P(mut~x) draw lhe requrred interiitce log1c
toritlc~l $Cction) otr<ut t (only tl~e relevunt Sl!lllWli ~hvuld
yfututeX) be shown)
fi>rever !3)
b. Wri1e it program to y_t!nerme -0 squnre
'1he 0<1da for l>lft is idcnlioul except thul it wm con the output o l' tbe Ilip-nop. ON
uses 1 (mutex) 111 pluct u( l'(mut~x). Wl>Ut and OFF pcrin<h< of the sq uure wul'c
1s the largt.st numbt-'1' .,r processes tbaJ c:m should be 7 bus c~•cles each
he inside the oriucal section at uuy (:!),
mllm<nt? l.et I. - (na .111.. .... ..a. ) n <:. 0 be a hsl
:t. 1 whose f>ascnl reprc:;enilltir.m is
b. 2 type list - reoord
c. J ne:o t list. val • ulle8er end
d. none o(abo\"c 'l'he f<,lle>Will~ l'uuetion return~ b li51 in
49 l'or n dutnbase relation R(u.. b. c. J ), where
the domwus ot' 11, b. c. d include m~y
al01mc vulues. only 1he folio\\ mg
wh1ch Ill• and II};. f. I sr:sl;J me
mtoiVhong:cd Comnlctc the functlon bV
function31 dej)endenctes untllhose that c~n l1lllug in tbe boxes. Write tl1e line nilull~r
be inJ'errod !'rom them holtl: aud .the content of Lhc box. in your answer
• ..,c
sheet.
b-o tl ~ ct..p (p : f lioi,) ; t WI ;
The rclutinn i•
2 •ar,,t: f lUI :
a. In firsl oon11~l f(Jrtn but nol in second
nomull fnrm
J """'
b. in second oormnt lorm but no~ in ~tird
unn11ul fnrm
4
S
lfp·nU-~ :-,.
doelfp T. -- aillhmcltooac o•c=:::J
.
~. 111 tl1ird norllllll filrm 6 .... bq:in
J. none nftho above
7 q : ... pt.neJCf :
50 Lei R (a, b, c) nnd S: (J. e, f) be two
relation£ in whi~h d is tbo fore1gn key of S 8 t:=:J :=f l
thai relct:S It> ~1e primary !<ey of ~ v , ; cq f.-r ;
Coo.•ider die following four opemtions on 10 I::=:J : •p t
R and S II I::=:J r• - , ..(I)
J. lnsen mlo R
12 ....
2, lnserllnlo S
3. Oelctc from R B cad
..j Delete fruw S (5)
Wlucb or the Ibllowing stalcmentS is true 53 . Consider a grnpb whose ~ertices dte pOints
ubout tho r~fellltttlnl itUettriiY oonstrnlnt j,l Ihe plone 11 ith int.,gcr co-ordinntes (x;.
ntx>ve? - ' >l such tlrut LS ;r S Jr aud lsys u. where
n ~ 2 is an mteger. Two vertices ~•. Yl) S-+ bSe
nnd (..:,.y~) ltr~ ndjoc"<:nt !f:fl.~- .fl i :> L S -+PQR
The weil!hl of 1m edge {(x,. }1 ),( .<1 .~·,)f P--obPc
It
Whot i8 the value ofF(u. 2)1
IC
..... Clld
..
17
19
1:e-J + "l ;
wrboiD (lllin + I) :
in the lnrell\lll nodes. of a a•-tree. with
IICO\'Cs(/ 2:l)1
12\
h. WIIJU Is rile maximum ~tnnbe.- of
20 ead
internnl nodes m n a·-ITI:e of order I
('onRider rile fhllnwrn~t piece. of 'C' ~ode 0
'"'" S2 lcii\"C\
frltgmem thnl removes dupltaucs rrmn WI ( I)
ordered list of huegers. C. wtraJ IS l~t:' llliiH111111.11 11\llttbco- Of
Node · · -.... I j 5 •= (J'Iodo 0 ...... irrl •j) lt.'a\ olS In a
~Ct!hl
a•-tree of onkr d w1d
II (It ~ I ,.
I
'Node . ,·~ •12 ;
t2l
65 ConStrUc:l a fintrc stmc mac~l,\c '"'h
•)•0 ; 1111 lnmmn number of ;,1atcs.. ncccptmg ull
I I - """" ;
&~nng,' ove1 (a. bl ~t•ch tltar the II umber nf
if(tt !: NUU.)/ 2 = I I .. - ; a's ts dl\~sihle b)' rwo and the nwnber of
b's ts dJVisJble by rhrce,
dx mum lococl : IS)
• /• 1; OIVL'fl L IS ~ lnnl!uugc ncccpt<d by n
thul
if v2 - ~ NUU.I caam 1at1 ; llni1e swe <UJ1Chine, show· lbru. L1' ood L~
ill'~: also accepr«l by some liJ1ile •une
...W• (t 21 • 1'1ULL)
1 111\tlunc~. where
J!' = {., j.1~· e I for some suing s' f
l~ : j., l ' obtainable ~ reVet1ling some
b1t urg111 I f
(5)
I
_
I' ....
---t +NIIIL
A language 1.. is u subsCl ofPasca·l "~th rhe
following CotiSIJllti.S:
n t:\pr~$~1011) IIIVOIVIIljl the O(lC!lltOU
• •· and '<" only
63 Assume tbe li>'t contains li elements (n~l b. Assignment staternt:~lb
in the foJI()winf! questions. c. ' while" srmemcnts nnd
rr. How muny nmcs Is tile rompnn><llt 111 II Couttll)uud ~wlcrlll:llll> \\1lh 1hc ~y11IR'
stAtement Sl made? beglll ' •• ~-·-c:nil '
111 Grve an un3Dlbib'llotts l!flmunar for L
b, Wl~u is rhc lltluilllunr null the 6!1. The lon~:un~:e L defined b)' d1c folio.-11111
ma_"unuln uw11b.:1 of 1imc:s stuiC1111ellt!i J!fiU1111lUr nil ow~ ul!t' of renlllr h1 le~::er dntn
mar\(<'(] $2 got C'CCLJI~~ in e.:pres~ion~ and assigrun~t star~menL\.
l21 (•cn-111111) :: - (LHS) :• (E)
"· Wlt;u i5 th~ slttniH~uuc~ or thiHnluc m
Ut" mrcger poinred to, by j when the (E) ; ; s (£) +(7)1{1)
funcrfon cmnpleres?
(2) (7) : : - (7) • (J'} !(Y)
A tf - IR:e or 111\lc:t 11 I~ H It« Ill whrclt
ench inremul node has bel'\'""" d and 2d (r) . : : • ld I<(£)>
k.ev valul!$. An maernal node -.irh M kl!)
vaiues M 1 I childreJL The root (if h isoo (LliS) ; : - id
huemnl lllld~) hli> lx:I W~Cll I Olld 2d ~") h ~ n:quir11d lu couvert e.\pressiOit w1d
Vnlues The distance of a node from the
~SSIIlUJllt!U stnn1!5 of L mto po;.il:ix stnogs
roor Is 1h~ lcng11r of the pmh from lhe rOO!
ItI ot' I~
th.11 use the type-spectfic operators (+, i), nb<we. 11 1~ known that al w me J"'llll nf
(.... r), (' , i\, ('. r), (:=, i) and( .=. r). time Juring Ute execution of this program
Write a !lyllltcX dirtctc.ltranslati<\n $Cherne fil'<: och\'lltion records txiS1 on the run-
to convert CJo.llfession and llSSij!!lmco t tjmc stock. Describe tbc nm·t.imc stntk- nt
strings llllll the JKlSt.fix form You mny Otis point Of lime by olcady indict~tins. the
llliswnc that the ownc lllld type uf u llllluw~ We top nf 0Jc stnok, Otc
wriabh• cun be ''blllinl'd by mukml,l th~ COntent~ Of Lhc stutic lml; mltl dvnonlio
function coiL~ ' p.ive-typc (tJ)' tmd 'give· 11nk. llncl ulli'Oalion of O>e locnl v~rinblcs
nltm11j,id)' reSJl!>"'tiwly. In ~.ach rccmd.
(5) 15\
Consider the followm[l rr<>!.llllnl l'rn[liiiCIII 70. h 1llowintt IS a stale table for some l"inlle
in I'OSI)lll state tllJJchinc.
..,_ Non s-. Outp.&t
sc.
JS tucA : input - U itlpUI • I
vwJ' : ~; A B. I II. I
~8 ~ B r,t D. l
-z,.....,; c 0 ,0 f. I
p .......... C; 0 c.o F. I
lqjo(•p 'cC • ) F C l C. I
G (', I D. I
H (',0 A. I
end ( •p C·)
begin ( • Jl<OC<'du~ 9 •I a. 1'intl cho e-tLuYalMce part.ition on the
~tJJtcs of the machine.
(2)
C: t• callto C · ) b Give Ute stotc table for tllo mini.mnl
A :( • allloA •l mncb.ioc. (Use upprtlpriut~ nomcs fot
the cquivulent stotcs. For ~-xnmplo tf
~t11tes X und Y aro cqm\'ulcnt the.l use
end ( • proce<lu"' 1.1 • 1 XY ns the ttltme tl>r the equivnlem ~tnte
in the minmilll machine),
- -'·:·lilaill (• ~A •) (JI
71 Let f •(iii+v)(HJ')\ ••·+-1' ~z)(ih.::)(H:)
a. W<prcs~ j "" th,· minmml sum of
8 ;( • call10 8 • ) producl,s. Write onl)' thennswer.
l3)
b. II the uutpul linc is s tuck. ul 0. for llo"
aid {• procedure A • ) mnn)- input eombinaLi<lns will the
l'llluoM}'be iuet>rrect'J
lqjn ( • Main • ) (2)
72 . Folltlii1US ilftating point number l'cmmnl •~
[liven
A ;(ocal110A •) f is n frnction roproseotcd by ~ 6-bit
mrtnlis.~u (include:; ~iW> ~it) in sign
; mttgnitudc fonn u is u 4-~io. e,\1)1>nont
{incloJ~s si!!Jl hll) m Stgn. mugnitudc fom>
end ( . Main • ) n ~ (/, C) "'-j 2' JS 3 fi<llltlng pOU1lllUJnbcr,
Assume. thm Otere ore no e<~Jls m till~ Let /1. = $4.75 in decimal tlnd
procedures mhor tlum 01e 11nes uJtlioutetl B = 9.75 iudecimnl
I t >JI 1:!
tL .Reprt$Cn.lA n nd a ~ Oonbn ~ pQinL procedllre ~-R (priariiY) ;
numbers an I he above (onnoL
(2) P ( muiAOlt} ;
b. 'Show the steps in,·o lvcd m llo~bns
poi·nt oddI~on M A llftd. B. if busy = uue tbeo
(2)
c. \Vha.tas d1e p~·rc:eutnge en·o1 {upto one R_teqUCIIed (prioriJy) := lnle :
poSJlu>n beyond dccunru pomt) m the
adrution operotlon in (b)'l else
( I)
begin
73. A cotlcurrcnt ~..stem consists of 3
processes usu'IJ!, n sluU'ed resource R tn n
II (proceed (priority]) ;
Jtan ..precmpUble nnd 1\lUtunlly cxclusn·e
nltt1lllef1 The pr~s!i~ hflve w1ique
priorities on lhe rnnge I . , 3 , 3 bcing the busy :- uue ;
lushest pnotit,y ll is rcqu1rcd to
synebronlze tb c processes suc.h thnl [he end
resource IS alway$ olloctlted to U)e Jughes1
).monty rcque:stc-r, The pseudo code ror tbc f•{ mulex) ;'
S\'Stcm is as follows~ Chvc the J:>Selldo cod.: fo1 the pn.lCC."dllft':
Slo~rcd dol~ n:: Icrn;c_ R
(5)
A p ougmm P ret~ds and procc,sses J()O(j
CQusecuii\'C records from a set1uentt,al fi le
It ,..l\."q\\1:$:\~d Pi - hook'"lln"' fBl!i\::: t .. :aU fnlu:aru,.:d hi r~lse • t
f stored on dovitc D \\ tlhoul usmg no~
~~·-; l-1Pie:ltt • r:~lll!.' ! I ~ intdaU7o:d In (;a~ • I tile system facilities. Gh·eu tbe following
Cod e- for processes - 11110..,...,.
bel\ln proccss
•nr- rri"Ti\)' • tn1~:~~r :.
-linleflfO -10-
......rc.- of 0 - - M Ut' hyoal-
llola
m_y-priorit~ . =
l epelll
••• : /• in dtcl"llnJr,-c l···;l• t
au.U.&o _ _ _ ·J-
rr:qucsc_R(my-pri()rity); W hnt is the clopsed time of P of
111 F eownins unbloc:.ked recordo; nnd P
r (proceed [my..,..iorityj): does fi.'Ol use liuO'eritlS'~
Wben. A process 1tknses • ff:l;ource. lh~ Wh3t tiKI CoUowing relational nlg1:1brJS
process wiUJ tbe smoJJ~-.t linlcstamp ( if c!.'<:pr.:ssioos "'" d~signud to dctllrDlinc
oP)") nmonl;'t those woiting fnr the
li ) 11al(~ INVOLVHD)-,.,.( (x..,
r<:!'Ource is ~warded the r.:sour""'·
(INVOI,VJ'.I)) ' "t"'{f'R\) .1))·
n_ Con • d~o.dlook over arise? II yes. INVOl-VE!))
3h ow how. If not. pro"" it.
(i i) n..,.(EMP)·n~m-11'.•••
(3)
((~1'.1-!Pl E;\[P)),
lr, Cnn a process P ever stn~ If yes.
!<how how. u·not. pr·ove it. (2) (Notc;pe{EMPl QOnccptWIUy m•k<-~ •
C<lp of EMP AUd nanH;'!I it K (p is ;:;illcd
the rana me o par:rt0r )