IpQuestion Paper Along With Answer Key
IpQuestion Paper Along With Answer Key
IpQuestion Paper Along With Answer Key
com/
Class 12th
int count=1;
do
{
if (count < 15)
jTextField.setText(“continue”);
else
jTextField.setText(“break”);
count+=3;
}while(count<=10);
(i)Given an int variable K with value 275. It is to be converted into equivalent string i.e. “275”. What are the
two ways of doing that? (2)
www.cbseguess.com
Other Educational Portals
www.icseguess.com | www.ignouguess.com | www.dulife.com | www.magicsense.com |
www.niosguess.com | www.iitguess.com
http://www.cbseguess.com/
3. (a) Which MySQL command helps you to see existing databases? (1)
(b) Giving suitable example explain the use of AS keyword with SELECT statement. (2)
(c) What is the significance of integrity constraints in MySQL table. (1)
(d) Rakesh wrongly dropped a table named as STUDENT.Can he recover this table. Justify your answer.
(2)
(e) Monica wants to display records of those employees whose salary column is not filled with any value.
She has written the following query :-
SELECT * FROM EMP WHERE SALARY NOT = NULL;
This query has some error(s). Write the correct query after removing the error(s). (2)
(f) Which method is used to remove leading and trailing spaces from the string? (1)
(g) Write SQL command to display the position of “My” in the string “Enjoying MySQL”. (1)
4. (a) What is the purpose of keyword (i) extends and (ii) super in java? (2)
(b) Write one point of similarity and one point of difference between for and while loop. (2)
(c) In JDBC coding, what method would you use to move to first row of recordset recSet? (1)
(d) Give the value of x after executing following Java code. Also find how many times the following loop will
execute? : (2)
int a=10, b=12, x=5, y=6;
while (a<=b)
{ if (a%2= =0)
x=x + y;
else
x=x-y;
a=a+1;
}
www.cbseguess.com
Other Educational Portals
www.icseguess.com | www.ignouguess.com | www.dulife.com | www.magicsense.com |
www.niosguess.com | www.iitguess.com
http://www.cbseguess.com/
(e) Blue Valley Public School has computerised its registration for class XI students. Given
below is the data entry form for same.
http://www.cbseguess.com/
Q5 (a) What will be the output of the following SQL queries: (2)
(i) SELECT 4+2*3;
(ii) SELECT 4+2*3 FROM STUDENT;
(Assume that table STUDENT has four records)
(b) Mr.Sodhicreated two tables with DEPTNOas Primarykeyin Table1 and ForeignKeyin
Table2.While inserting a rowin Table2.Mr.Sodhi is notable to entera value in the column
DEPTNO.Whatcould be the possible reason and solution forit? (2)
(c) Write SQL commands for the questions from (i) to (vi) on the basis of table SCHOLARS(1x6=6)
(i) To display Name, Adm_No of those students who joined after year 2012.
(ii) To display all the information in descending order of Adm_No.
(iii) To add record with the following data:
8326, “ANKIT”, “2013-10-25”
(iv) To count unique SEMESTER numbers in given table.
(v) To make Adm_No as Primary Key.
(vi) To change the FEE of VIJAY from 35000 to 30000.
6. (a) Create table CLUB as per following Table Instance Chart. (2)
Field Name Data type Size Constraint
Member_No Numeric 5 Primary Key
Member_Name Varchar 40 Not Null
Age Numeric 2
Type Varchar 10 Temporary or Permanent
Games Varchar 20 Foreign Key= Master(Facilities)
Fees Numeric 6,2 Non negative
Fees_Date Date
(b) In a Database Karnataka_Sangam there are two tables with the instances given below: (2x3=6)
Table : STUDENTS
ADMNO NAME CLASS SEC RNO ADDRESS PHONE
1211 MEENA 12A D 4 A-26 3245678
1212 VANI 10A D 1 B-25 5456789
1213 MEENA 12B A 1 NULL NULL
1214 KARISH 10B B 3 AB-234 4567890
1215 SURAJ 11A C 2 ZW12 4345677
Table : SPORTS
ADMNO GAME COACHNAME GRADE
1215 CRICKET MR. RAVI A
1213 VOLLEYBALL MR. AMANDEEP B
1211 VOLLEYBALL MR. GOVARDHAN A
1212 BASKET BALL MR TEWARI B
(i) To display name and gameof those students whoseaddress is available in STUDENTS table.
(ii) To display Name and Class from STUDENTS table and corresponding Grade from SPORTS table.
(iii) To display Names of the students who are studying in class 12 and their corresponding
Coachnames from STUDENTS and SPORTS table.
(c) In a database School there are two tables Member and Division shown below. (1 x 2=2)
Table: MEMBER
EmpId Name Pay Divno
1001 Shankhya 34000 10
1002 Ridhima 32000 10
1003 Sunish 45000 20
Table: DIVISION
Divno Divname Location
10 Media TF02
20 Dance FF02
30 Production SF01
Email Id :iqbal_mailbox@rediffmail.com
ANSWER KEY
INFORMATICS PRACTICES (O65)
CLASS XII
whose source codes are available openly to the users. The users can modify and redistribute them without
any restriction and can use it for unlimited time.
(d) (i) Ring Topology (Loop) (ii) Star Topology (Radial)
(e) The MAC (Media Access Control) address refers to the physical address assigned by NIC manufacturer.
Example of MAC address is : 12:C8:05:67:2D: FB
It consumes 6 bytes.
(f) (i) FLOSS : Free Libre and Open Source Software (ii) Network Interface Unit
(g) Various protection methods such as (i) Authorization (ii) Authentication (iii) Firewall etc. can be used.
2 (a)
HTML XML
It is presentation oriented not data oriented It supports data representation through standard
data structure
It does not have data validation capabilities It has data validation capabilities
With it data cannot be shared across applications With it same data can be viewed in multiple ways
by different user groups and applications
It focuses on presentation It focuses on data
(b) setVisible(true);
(c) setText() Method
(d)
<P> tag <BR> tag
It is container tag It is empty tag
It can take attributes No attribute is given
It leaves one blank line before start of It leaves no blank line
new paragraph
(e) Keyword void is used with function declaration/definition denotes that function will not return any value
to the calling function.
(f) Conditional operator (?) also known as Ternary operator (?) works on three operands. It can be used in
place if else statement. This operator is used to check a condition and produce logical result; either True or
False. The syntax is:
Var= condition ? expression1 : expression2;
(g) Constructor function
(i) has same name as that of class
(ii) has no return type not even void
(h) jTextField.setText(“break”); will never execute.
(i) (1) “ ”+ K; (2) String.valueOf(K);
4 (a)(i) Keyword extends is used to inheritthe properties of base class by derived class.
(ii)Keyword super is used to access the base class constructor and overridden function.
(b)Similarity: Both are entry control (pre-tested) iteration statements.
Difference: (i) In case of while statement initialization, condition and updation steps are separately defined.
Whereas, in case of for statement initialization, condition and updation steps are defined in a single row
separated by ; (semicolon). Coding size in case of for loop is compact.
(ii)forstatement is used when we want to execute the loop for fixed number of times
whereas; while statement is used to execute the instructions till the condition is true.
www.cbseguess.com
Other Educational Portals
www.icseguess.com | www.ignouguess.com | www.dulife.com | www.magicsense.com |
www.niosguess.com | www.iitguess.com
http://www.cbseguess.com/
(c) recset.first();
(d) Value of x will be 11 and loop will execute 3 times.
(e) (i) jTextField1.setEditable(false); jTextField2.setEditable(false);
(iv) System.exit(0);
www.cbseguess.com
Other Educational Portals
www.icseguess.com | www.ignouguess.com | www.dulife.com | www.magicsense.com |
www.niosguess.com | www.iitguess.com
http://www.cbseguess.com/
(ii) E-Learning sites make students’ learning more fast with the help of audio visual tools.
(iii) Students are more engaged and able to develop latest skills.
www.cbseguess.com
Other Educational Portals
www.icseguess.com | www.ignouguess.com | www.dulife.com | www.magicsense.com |
www.niosguess.com | www.iitguess.com