Page 235 - Computer Science Class 11 With Functions
P. 235
6. WriStl nl progrnel ShnSl ncctpStl froel Shtl uttrl Shtl vnauttl ofl Shrttl faonSingl poinSl vnrinbattl n,l b,l c,l nndl cnacuanSttl rooStl
2
ofl nl qundrnSicl tqunSion:l nx l +l bxl +l cl =l 0l whtrtl nl itl noSl tqunal Sol ztro.l Uttl nl uttr-dtfintdl funcSionl Sol cnacuanStl Shtl
rooSt.
7. WriStlnlprogrnelShnSlSnkttlShtltidtloflnltqunrtl(inlctnSietStrt)lnndlnlchnrncStrl(tiShtrl'A'lorl'P'l)lntlnnlinpuSlfroelShtluttr.l
ThtlprogrnelthouadlditpanylShtlnrtnlorlptrietStrloflShtltqunrt,ldtptndinglonlwhtShtrlShtlinpuSlchnrncStrlitlAlorlP.lAato,l
Shtlprogrnelthouadlditpanylnnltrrorletttngt,liflnlchnrncStrloShtrlShnnlAlorlPllitltnStrtd.
8. WriStlnluttr-dtfintdlfuncSionlSolrtndlSwolnuebtrtlnndlrtSurnlShtlpotiSivtldifftrtnctlbtSwttnlShte.l
9. WriStlnlprogrnelShnSlncctpStlShtlnnetlnndlenrktloflnltSudtnSlntlShtlinpuSlfroelShtluttrlnndlprinStlShtlgrndttlnccordingl
SolShtlptrctnSngtltcortdlbylShtltSudtnS.lThtluttrlinStrncSionlwiShlPyShonlinStrprtStrlnpptnrtlntlfoaaowt:l
Enter your Name: Veena Dua
Enter your Marks: 130
Enter Maximum marks in examination: 200
Your Grade is: B
UttlShtlfoaaowinglSnbatlntlnlrtftrtnctlcriStrin.
Percentage Grade
>=90 A
>=75lnndl<90 B
>=60lnndl<75 C
>=40lnndl<60 D
>=l33lnndl<40 E
<33 F
Uttluttr-dtfintdlfuncSiontlSolncctpSldnSnlnndlcnacuanStlgrndtt.
10. WriStlnlprogrnelSolrtndlnlchnrncStrlnndlchtcklwhtShtrliSlitlnnlupptrcnttlchnrncStr,lnlaowtrcnttlchnrncStr,lorlnldigiS.lForl
txnepat,lonlrtndinglJlntlShtlinpuSlchnrncStr,lShtlprogrnelthouadlouSpuS:
J is an uppercase character.lll
11. AithwnrynlhntlbttnlnttigntdlnlprojtcSlSolfindlShtlBodylMnttlIndtxl(BMI)loflShtltSudtnStloflhtrlcantt.lThtlforeuanlSol
cnacuanStllBMIlit
BMI=lwtighSl(inlkg)l/lhtighSl(inle) 2
WriStlnlprogrnelShnSlenylnttitSlAithwnrynlinlnchitvinglShtlnttigntdlSntk.
Assertion and Reasoning Based Questions
The following questions are assertion(A) and reasoning(R) based. Mark the correct choice as
a. Both A and R are true and R is the correct explanation of A
b. Both A and R are true and R is not the correct explanation of A
c. A is true but R is false
d. A is false but R is true
AtttrSion(A): AnlifltSnStetnSlitlnltiepatltSnStetnS.
Rtntoning(R): AltiepatltSnStetnSlnpptnrtlbyliSttaflinlnlaint.
Case Based Questions
1. RuepnlitlvtrylpnrSicuanrlnbouSlhtrlbodylwtighS.lRtctnSay,lhtrlfritndlSoadlhtrlShnSlBodylMnttlIndtx(BMI)litlShtlcorrtcSl
2
etnturtloflyourlbodylfnS.lThtlforeuanlSolcnacuanStlBMIlitl(wtighS/htighS ),lwhtrtlwtighSlitlinlkglnndlhtighSlitlinletStrt.l
RuepnlwnnStlSoldtvtaoplnlprogrnelinlPyShonlShnSlncctpStlwtighSlinlkiaogrnetlnndlhtighSlinletStrtlnndlcnacuanSttlBMI.l
Conditonnal SnStetnSt 233

