Sample Paper Informatics Practices Class - Xii

Download as pdf or txt
Download as pdf or txt
You are on page 1of 6

SAMPLE PAPER

INFORMATICS PRACTICES
CLASS - XII
General Instructions:
 Please check that this question paper contains ======== printed pages.
 Please check that this question papers contains 7 questions.
 Please write down the Serial Number of the question before attempting it.
 First 15 minutes time has been allotted to read this question paper. The students
will read the question paper only and will not write any answer on the answer-
book during first 15 minutes.
 All questions are compulsory.
 Answer the questions after carefully reading the text.

1 (a) Explain how java codes are compiled and run. 2


.
(b) What will be the output of the following code segments: 2
int a=5, b=10, c=9, d=8;
System.out.println(“” + ((a++)+(++c)-(--b)+(d--));
System.out.println(“” + ((a>b)?(c>d)?(++d):35:(--b)));
(c) Convert the following code segment using switch-case construct: 2
int num = Integer.parseInt(txtNum.getText());
if(num>=2 && num<=5)
txtRes.setText(“Prime”);
else if(num==6 || num==8 || num==10)
txtRes.setText(“Even”);
else
txtRes.setText(“Not Valid”);
(d) Predict the output of the following java construct: 2
int m=5;
int prod=1;
int i=1;
while(i<=5)
{
prod=prod+prod*(m%2);
--m;
++i;
}
System.out.println(“”+prod);
(e) What is the difference between an ordinary method and a Constructor? 2
2 (a) Differentiate between DDL and DML commands. 2
.
(b) Differentiate between TRUNCATE TABLE and DROP TABLE in SQL. 2
(c) What does isolation property imply? 2
(d) Explain atomicity property of transaction. 2
(e) Briefly explain the concept of ResultSet method. Also discuss the next() and 2
first() methods.
3 (a) 2+2+
. 1

(b) What is Dialog Box? 2


(c) Write minimum four features of XML. 2
(d) What do you understand by option VLINK used with <BODY> tag? 2
(e) 2
(f) 2

4 (a) 2
.
(b) 2

(c) 2

(d) 2

(e) Explain abstract class. 2


5
.

6 (a) 8
.
(b) 2

7 (a) 3
.

(b) 2

You might also like