TBS Undri, Class IX Final Paper Suhani M.
TBS Undri, Class IX Final Paper Suhani M.
statements
class abstraction
d)data usertype
school. the B. each)
mark
(one as
100
Marks-
theminutes
writinaSection
in
aiven
[20]
Mks
Tot another java
d)object keyword
d)
the
after Math.abs(known
is
Math.max(-remaining
4,-2)
by paner
from
forSections
are from aof
component d)exic)fotr-type
controlledmode d)shorthand
d)4.0 operands,
is
provided allowed questions
questions properties loop. data d)mixed
UNDRI 15 question c)Inheritance
b)Encapsulation
a)Polymorphism as ofprocessing
APPLICATIONS
COMPUTER
2022-23 Max
EXAMINATION
FINAL first option
c)function iterative known
another
pperthe tiime
two Marks) two
SCHOOL, the four questions
allAttempt correct c)literal
individual c)coercion
during theinto ofparts
reading the on fixed to is c)2
with
c)binary
any
(2Hours) ne is divided brackets[] (40 acquires stresses Conversion
converted deals skip
of5
1Page
CO-ED on write Paper andor the
witten questionsA SECTION languageeach
a expression arithmeticcanisiteration
in is A
to spent Section
thisPaper
write
class b)coding
as
defined b)implicit whichoperator.
BISHOP'S allowedheadof and
as b)token
defined b)whileqetstype b)-4.0 operatorb)unarythat
be
must be Thisfrom answerawhich
statement
to
for
marks
oriented isloop type
the the next
be is theanswers.
questions is intervention,of data aritthmetic
Paper by
THE not timeat intended correctDrocess Procedure statement. a)do-while
a)identifier the
Conversion.
a)explicitoutput
to
umpjup
asknown
is
thiswill Thisgiven a)ternary
YoU all
1.Question
the The a)data When Thea)2.0 Iheand
-IXto
Answerstime Attempt
Class The An
Choose 3.A 6. 7. b.
The 1. 2. 5.
4
d)for
c)return
a)break b)continue
9. Predict the output:
int a=14, b=2;
if(a>b && a%b==0)
System.out. printin(a ++);
else
System.out.printin(--a); d)7
a)15 b)14 c)13
10, Predict the output of the code snippet.
int i=0;
for(i=5; i>1; i-)
if(1%2==0)
break;
System.out.printin(i);
a) 1 b)4 c) 2 d)5
result in true or false:
11. Indicate whether the following statements
int a=10, b=20;
if( (a<b) ||(a==b)) d)o
a)true b)false c)1
an object or
12. This is a special purpose literal used to initialise
reference variable. literal
a)boolean literal b)Null literal c)String literal d)float
Kewrite the following snippet using while loop instead of for loop.
int f=1,;
for(i=1;i<=5;i++)
{ f*=i;
System.out.println();
(D) Predict the output for the following: int x=4;
X+=(*++)+(++x)+x;
(c) Given the output of the following code :
i) Math.abs(Math.ceil-4.6);
i) Math.round(Math.cbrt(125));
p=p+i;
System.out.print(p+* ");
itt;
}while(i<5);
(e) Give the output of the snippet:
int a=1;
while(++a<=10)
if(a==5)
break;
System.out.printin(a);
Page 3 of 5
(9) Wite java exptession for A
statement
(h) witchcse
CoIvert the following f else' stuctuointo
if(cha Y)
{xx-10; System,out.println(x),}
else if(chy)
(x 10; System.out.println(x):)
() Correct the errors In the glven progran:
int a=45, b70, c65.45:
suma+b;
diff=c-b;
System.out.println(sum,diff);
() Convert the following while loop into do while loop
int m=5,n= 10;
while(n> 1)
{System.out.println(mn);
Page 4 ol 5
Question
Write a 6. (15)
program to print the pattern as foliows:
543
S432
54321
Quest
Write aioprogram
digit
n7. [15)
to check whether the number entered by the user is a one
number
display the or a two digit number or athree digit number. Otherwise,
message "The number enteredis more than three digits".
Use the if-else
structure only.
Question
Write
8. (15]
a menu
of a rectangle driven
as per program
the user'stochoice.
calculateAccept
and display the area
the length and orbreadth
perimeter
of a
rectangle.
Hint: area=length*breadth
Perimeter=2xiength+2*breadth