0% found this document useful (0 votes)
23 views

Decision Control Statements

Copyright
© © All Rights Reserved
Available Formats
Download as PDF or read online on Scribd
0% found this document useful (0 votes)
23 views

Decision Control Statements

Copyright
© © All Rights Reserved
Available Formats
Download as PDF or read online on Scribd
You are on page 1/ 26
= Be = |< ciSaeton: ce tee Aiton Br =a DAL _Ured ko toe ony Or wy plot Pf oy ante. uatan Yes _empceprion js brite _ A t x Ye ent. 2 | — aa - en “Branthing Stokomant | _____— = — j > fs [tens ttse| [tai thsa) farted 4), AY stoboment + The i Aboke man’ in Mar Ain alest onion, t Lon di Mien oo pin enn und An Yoisbtakemint Sik panatd saith cobain — gece Ly {ran dition) & stoktiminr =) abe gel Sinko 21 ae z2-- Stoke anki ie et “vests oly Mo progr min. fae + rest of Vine code. 1) Wa B10: u : VD I print (“5 in not we +n 10") ay Mv o 0; % panies 1 ik -pastiut nai By a dt --- _ Stara RESO) Ti Sos sang. Sel | Jno ten aj hen oe ik krye hs _ is knecuted and he =e _ fat. Gk mauur ts day ‘ack unitar Sh Bae be provichid wily condikion Noor Be pall tines somdikior. i pbk pron. Hae hae Jolocle bs _ Tratanted ater QQ unt 9 paeort d Suntan + ka ik Comm ditien ys oukernont 4 Jake mint 2 Stattmment =) ase Of Stones eee ee en ee pert stoloment = yest of Xin _tode. 4i Hasan > Flow tart: ai Eixabnn ts, ols olf ale pdaastnony ti ——b_ Ns eval Ginput ("Enter the! no. ¥")) 1 i N A)==OQ 2 —$§t privk ("no 'S = eu en”) | rint("ne. js odd”) 2)| opr = inpual Ener opyotey 5") pe ee a Orink(" addition ig”, +p) ese? int’ eo 4) | Thao elit.. se: ii ¢ V _{n Yad srolerenk i% i> provided coitin condition + | wWhin ereriHen starts i wih Arle bas cantik 1 irs Warn “14 bone’ in taeeked i fab, 1 Xoon ik wid mmo yers boo. ®t ohith ib a 4 a Yorn “ahah = Sloth’ js eteuted i} dale | #itlbot Wo vans WSs None SOUS Teer ere ele ee | | Ty we As no Niegik ye dn ehih bya a | Tr is also tale on ‘eon cada” oe Yaad — eee inthe ge Sto¥emont- 1) E t sus Stn ke mont i Dest Of Haw ornd es 9 >Flow-Charti + Lig 4 , Aeste sd 2.6:0 4 { Lhe 1a Ob) Ia) Brink UP yder mark's”) ‘hese Mork = mM = (rom Canfas b9 _ i} m>=75: (a print (“Di yin chon”) | ieeansa tit wm >= 60 print (* Picst dass) ti, m7 =50 print ( Sersnd claps”) it yn >= 40: print Tir ds chass”). | e\ set : + print(* Paik") ae Oe ink Co gut (Enter i ae) i | ‘b= {nk Lingus Oe ner. 2 2 yy Z| C= ine Unpud tember 3.) YW (o>b) and -ta>c)+ print (S ai oro eney OA) = | dik (ae ond lesays | Prink tC is thr greatest no.) 4 e— a L Nested v » Ae ‘ast sath, calivasnl tania, ee | one. Conditianal “pier js pee | in _gnotnen Condiisnol poker ent sas ust ee ee SA in Nisbet ComAiienal foe |. BONS Se [eg nisted ih Sens su, [eet rented it -- thity oer. e a : 5 4 a : us as rndiien ip cthttees soly when quker ogndibion ine iat. natal Tht cod Lramples + ha ay) progeam to “Hird ves gti = Si ae aero = int Gap erie No”) te =o, (E O2O* PrinkOipoeis Gow se Tse ae pring ngs is: Tiga veyiens «sh eee ‘en print (no. 18 eg) i : a lig ee a oh de greats am ongs thin 192 a r # assign three “no. [hs as igi 5s, Tha pif a2 \o. ed C We Art prink (Mis tx kent”) eae - a Ad an tb: prink Cc is star greater’) [ee els usr < by. i, bot Te . Prink(' Cis we greater’ ") | |e noated teh pape bal # Api o fru valits | = Trae f= ins Gnpub("P ker ono. 0) # chore Yt _ tan dition 3} Ch e= Set — - O° : tt oucs en na key rege rises “punta {sat aa bi ot boas er a. ie Pr ageaes” | iid nvih ged oP t Pit, aod aay 4 diy nh) = Wigesepe a tot 1) aiAt . berths 169 olofsAhAG) » ast | = = Chap. 2. Looping / Luzatiue Stam ents pd __Loopin’ Looping, or Livrotion is ‘9 _Hevpnigue te 1) — | odows to txewke O stk of stoleynenk ae baa, a ondor Inlorks of codes epee oon dition ts trues i 1 aration Reape pee ca Fakements or hlocbs nk thde jn = Codhrd oo orien. i Thue ore thee =n of a Loopin wn Fa Toap] sh ep “auptoke ; Uniihd the Pee ae wndivion id Fatar Yoon ik will eit me OT Cte doop and ‘yest of tode’ in enecuked . < pelgueenaa oe e it “a p a: has seis a Oh Break | eo Ya tiyusotd Am. \ Dupin ten ywonith i io ‘oben k 1 Stolement Drea rest ot Maa Progra flowehark* — + Examples a hill Deogrom Ao demonsivake hetak. % ah Sars ys in_congeQ luigi) oa pa ts Pash ee oe Jsrrar 5 i a ah | 2) a Program to demonstrate break. L i: 5 [ “WOE 5 Si Dey — i erink UD i ik 1 ="9108, — . brea Jaya 1 I 3) 4 Progen on to dumonsirake brtale | Sor in Longe (1 Wy drrola, I ——_Frowenorts ae J slau LL bins dads wh pelt seimbiet Ete eae 4. ee Can don a det { coatic ne 1 i T Loops biota} { + | rest of code | |Exomple: 1) 4e Progyam 4) print odd no. tor 4 sina Vou): it ise 220) conHn We print Ui fnd =") 2 # Prowram te priw tyun . no iz 4 While j2=\n0° if} Yaid ‘ Prink (i Undies) 2) a } 3) ete - . iin ‘angi “Ob. ee - ik 1% 5<.0 it _ i es RSC ie “—_ Poss: Seales 3 Pass is 9 bw Quth an ee is a nuw)” tokement “ik dota nothing | just m \ 5 [pop { tendivie Aye Stobem unto! Pose” Som unt EL yest Of mde. Example : bes, # program to- print 4 bait aAtgihon Roe St in tangs (I Se) = Print Uy end =* pass erink (sit) + progam to tnd totorial. Ave | y n= ink linpyk(y) Pai range { 4 ne): % fac= ino *4f Pass 4 {ivey | qohon execution Stop bo, ns oop jd ger execubed | 4oecome false, ine \on geks derminated and — else -hineR js ae Jonp (cendikiom) * An era nt tb | Soko e | | tor var in rangels. ect Loop ese 4 stakomint est Of ode print 49 aigitss tor 1 in conge (hy WV) print (i) XN U8) | Printt\ roth | done”) LH edse wit While Soop. S 5 eh i= (iniiod vata) eI Win, (14s 95! i l pints ate) in or ummt J ay cremmont | ehats | ce oe F | List Of code : i 12% Jprogray ts print 41% 40 sight E while fe=io privk {iy Losbyy # SS US pri we CUA

You might also like