CBSE Previous Year Solved  Papers  Class 12 Computer Science Outside Delhi 2011

Time allowed : 3 hours                                                                                           Maximum Marks: 70

General Instructions :

  1.  There are a total of 26 questions and five sections in the question paper, All questions are compulsory.
  2. Section A contains question number 1 to 5, Very Short Answer type questions of one mark each.
  3.  Section B contains question number 6 to 10, Short Answer type I questions of two marks each.
  4.  Section C contains question number 11 to 22, Short Answer type II questions of three marks each.
  5.  Section D contains question number 23, Value Based Question of four marks.
  6. Section E contains question number 24 to 26, Long Answer type questions of five marks each.
  7. There is no overall choice in the question paper, however, an internal choice is provided in one question of two marks, one question of three marks and all three questions of five marks. An examined is to attempt any one of the questions out of two given in the question paper with the same question number.

Question.1. (a) What is the difference – between Type Casting and Automatic Type Conversion ? Also, give suitable C++ code to illustrate both.
Answer:
Type Casting : It is an user defined explicit type conversion which operand in an expression is forced to be a specific data type.
SYNTAX:-
(type) expression
Automatic Type Conversion : In case of an expression in which operands of different type are mixed, an implicit type conversion is performed by the computer which automatically converts all operand upto the type of largest operand.
(b) Write the names of the header files, whichis/are essentially required to run/execute the following C++ code:
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-1
Answer: #include<iostream.h> and #include<ctype.h>
(c) Rewrite the following program after removing the syntactical errors (if any). Underline each correction.
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-2
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-3
(d) Find the output of the following program :
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-4
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-5
Answer:
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-6
(e) Find the output of the following program:
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-7
Answer:
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-8
(f) Go through the C++ code shown below, and find out the possible output or output from the suggested output options (i) to (iv). Also, write the least value and highest value, which can be assigned to the variable MyNum.
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-9
Answer:
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-10

Question.2. (a) Differentiate between Constructor and Destructor function with respect to Object Oriented Programming.
Answer:
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-11
(b) Write the output of the following C++ code. Also, write the name of feature of Object Oriented Programming used in the following prQgram jointly illustrated by the functions [I]to[IV].
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-12
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-13
Answer:
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-14
(c) Define a class Applicant in C++ with following description:
Private Members

  •  A data member ANo (Admission Number) of type long
  •  A data member Name of type string
  •  A data member Agg (Aggregate Marks) of type float
  • A data member Grade of type char
  •  A member function GradeMe( ) to find the Grade as per the Aggregate Marks obtained by a student. Equivalent Aggregate Marks range and the respective Grades are shown as follows:cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-15

Public members

  • A function ENTER( ) to allow user to enter values for ANo, Name, Agg & call function GradeMeO to find the Grade.
  •  A function Result( ) to allow user to view the content of all the data members.

Answer:
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-16
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-17
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-18
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-19
(d) Answer the question (i) to (iv) based on the following:
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-20
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-21
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-22

  1. Write the names of member functions, which are accessible from objects of class course.
  2. Write the names of all the data members, which is /are accessible from member function commence of class course.
  3. Write the names of all the members, which are accessible from objects of class teacher.
  4.  Which type of inheritance is illustrated in the above C++ code?

Answer:

  1.  Result( ), Student( ), Enroll ( ), Display( ), TCode, TName, Salary
  2. Data member from Students, Private Members from Teacher
  3. TCode, TName, Salary
  4. Multiple Inheritance

Question.3.(a) Write a Get2Froml() function in C++ to transfer the content from one array ALL[ ] to two different arrays Odd[ ] and Even[ ]. The Odd[ ] array shotdd contain the values from odd position (1, 3, 5,….) of ALL[ ] and Even[ ] array should contain the value from even positions (0, 2, 4, ….) ofALL[].
Example:
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-23
Answer.
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-24
(b) An array G[50] [20] is stored in the memory along the row with each of its element occupying 8 bytes, find out the location of G[10] [15], if G[0] [0] is stored at 4200.
Answer:
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-25
(c) Write a function in C++ to perform Delete operation on a dynamically allocated Queue containing Members details as given in the following definition of NODE.
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-26
Answer:
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-27
(d) Write a DSUM () function in C++ to find sum of Diagonal Elements from NxN matrix.
(Assuming that the N is a odd number)
Answer:
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-28
(e) Evaluate the following postfix notation of expression: True, False, NOT, AND, True, True, AND, OR
Answer:
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-29

Question.4. (a) Observe the program segment given below carefully and fill the blanks marked as Statement 1 and Statement 2 using seekg( ), seekp( ), tellp( ) and tellg( ) functions for performing the required task.
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-30
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-31
Answer.
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-32
(b) Write a function in C++to count the no. of “He” or “She” words present in a text file “STORY.TXT”.  If the file “STORY.TXT” content is as follows:
He is playing in the ground. She is playing with her dolls.
The output of the function should be
Count of He/She in file :
Answer:
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-33
(c)Write a function in C++ to search for a laptop from a binary file “CAMERA.DAT” containing the objects of class CAMERA (as defined below). The user should enter the Model No and the function should search and display the details of the camera.
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-34
Answer:
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-35

Question.5. (a) What do you understand by Selection and Projection operations in relational algebra ?
Answer : A selection is a unary operation written a σa (R) whereα is a propositional formula that consists of atoms as allowed in the normal selection and the logical operator ∩(and), ∪ (or) and (negation). The selection selects all those tuples in R for which α holds.
A projection a unary operation written as π a1,a2,……a(R) where a1,a2,……an is a set of attribute name. The result of such projection is defined as the set that is obtained when all the tuples in R are restricted to the set. Consider the following tables EMPLOYEE and SALGRADE and answer (b) and (c) parts of this question:
Table: EMPLOYEE
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-36
(b) Write SQL commands for the following statements:
(i) To display the details of all EMPLOYEES, descending order ofDOJ.
(ii)To display NAME and DESIG of those EMPLOYEES, whose SGRADE is either S02 or S03.
(iii)To display the content of all the EMPLOYEES table, whose DOJ is in between ‘09-FEB-2006’ and ‘08-AUG-2009’.
(iv)To add a new row with the following:
(v) 109, ‘Harish Roy’, ‘HEAD-LF, ‘S02’. ‘09-SEP-2007, ‘21- APR-1983’
Answer:
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-37
(c) Give the output of the following SQL queries :
(i) SELECT COUNT (SGRADE), SGRADE FROM EMPLOYEE GROUP BY SGRADE;
(ii)SELECT MIN (DOB), MAX(DOJ) FROM EMPLOYEE;
(iii)SELECT Name, SALARY FROM EMPLOYEE E, SALGRAGE S WHERE E.SGRADE = S.SGRADE AND E.ECODE<103;
(iv) SELECT SGRADE, SALARY+HRA FROM SALGRADE WHERE SGARDE =‘S02’;
Answer:
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-38

Question.6.(a) Verify the following using Truth Table
X+Y.Z= (X+Y). (X+Z)
Answer:
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-39
(b) ’Write the equivalent Boolean Expression for the following – Logic Circuit.
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-40
Answer:F(P, Q, R)=P.Q+P.R
(c) Write the SOP form of a Boolean function F, which is represented in a truth table as follows:
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-201141
Answer :
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-42
(d) Reduce the following Boolean Expression using K-Map:  F(A, B, C, D) = ∑ (0, 1, 2, 4, 5, 6, 8, 10)
Answer:
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-43

Question.7.(a) In networking what is WAN? How is it different from LAN?
Answer:
A Wide Area Network (WAN) is a network that covers a broad area (i.e., any telecommunications network that links across metropolitan, regional, national or international boundaries) using leased telecommunication lines.
LAN is completely different from WAN. LAN is only limited for connecting systems within the same building, whereas, WAN is extended for connection between countries, cities, etc.
(b) Differentiate between XML and HTML.
Answer:
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-44
(c) What is WEB2.0 ?
Answer : WEB2.0 is associated with web applications that facilitates participatory information sharing, interoperability, user centered design and collaboration on the World Web Wide. It allows user to interact and collaborate with each other in a Social Media dialogue as creators of user generates
content in a virtual community.
(d) Out of the following, identify client side script(s) and server side script(s)
(a) javascripy
(b) ASP
(c) vbscript
(d) JSP Answer:
JavaScript & VBScript are client side scripts. JSP & ASP are server side scripts.
(e) Great Studies University is setting up its Academic schools at Sunder Nagar and planning to set up a network. The university has 3 academic schools and one administration center as shown in the diagram below:
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-45
Number of Computers in each of the School / Center is follows :
cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-46

  1.  Suggest the most suitable place (i.e. Schools / Center) to install the server of this university with a suitable reason.
  2.  Suggest an ideal layout for connecting these schools/ center for a wired connectivity.
  3.  Which device you will suggest to be placed/ installed in each of these schools / center to efficiently connect all the computers with in these schools / center.
  4.  The university is planning to connect its admission office in the closest big city, which is more than 350km from the university. WTiich type of network out of LAN, MAN or WAN will be formed? Justify your answer.

Answer:

  1.  Admin Center is suitable to install server because it has the maximum number of computers.
  2. cbse-previous-year-solved-papers-class-12-computer-science-outside-delhi-2011-47
  3.  Switch
  4.  WAN because given distance is more than the range of LAN and MAN.

(f)Compare open source software and proprietary software.
Answer: Open source software refers to a program or software in which the source code (the form of the program when a programmer writes a program in a particular programming language) is available to the general public for use and/or modification from its original design free of charge. Proprietary software is software that is owned by an individual or a company (usually the one that developed it). There are almost always major restrictions on its use, and its source code is almost always kept secret.
(g) What are cookies?
Answer : Cookies are a small piece of data sent from a website and stored in a user’s web browser while the user is browsing that website.