0% found this document useful (0 votes)
25 views8 pages

Computer Final Chap Wise Phases Xii

The document contains notes on various computer science topics, including Operating Systems, Software Development Life Cycle (SDLC), Object-Oriented Programming (OOP) in C++, Control Structures, Arrays and Strings, and Functions. Each chapter includes multiple-choice questions, short answer questions, and programming tasks to assess understanding of the material. The notes are prepared by Rizwan Mirza and serve as a study guide for students.

Uploaded by

itshashir227
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
25 views8 pages

Computer Final Chap Wise Phases Xii

The document contains notes on various computer science topics, including Operating Systems, Software Development Life Cycle (SDLC), Object-Oriented Programming (OOP) in C++, Control Structures, Arrays and Strings, and Functions. Each chapter includes multiple-choice questions, short answer questions, and programming tasks to assess understanding of the material. The notes are prepared by Rizwan Mirza and serve as a study guide for students.

Uploaded by

itshashir227
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 8

XII NOTES COMPUTER

CHAPTER# 1 OPERATING SYSTEM


1. In which operating system same types of jobs are ground together and executed one by one?
A. Multiprogramming OS C. B a tc h P r o c e s s ing OS
B. Time Sharing OS D. Re a l- Ti m e OS
2. In which state a process is waiting to be assigned to the processor by the OS scheduler?
A. New State C. Ready State
B. Running State D. Waiting State
3. Which of the following manages the allocation of computer resources during program
execution?
A. File Management C. I/O Management
B. Process Management D. M e m o r y M a na g e m e nt
4. An executed instance of a program is called:
A. Task C. Process
B. Work D. Thr e a d
5. ________ can direct access to the data segment of its process:
A. Thread C. I/O Devices
B. Task D. Program
6. Which operating system is more secure and very fast?
A. DOS C. Window
B. Linux D. Mac OS
7. In the ________operating system CPU is rapidly switched b/w programs so that all the
programs are executed at the same time.
A. Multiprogramming OS C. Time-Sharing OS
B. Embedded OS D. Real-Time OS
8. Which operating system is used in Home appliances?
A. Distributed OS C. Embedded OS
B. Real-Time OS D. Multitasking OS
9. Which of the following creates users’ group and assigns privileges to them?
A. Network Management C. File Management
B. I/O Management D. Memory Management
SECTION – B
i. Why operating system (OS) is necessary for computer? Give three reasons.
ii. Differentiate between GUI and CLI interfaces.
iii. Mention three advantages of the UNIX operating system.
iv. Define multi-threading with an example.
v. Why memory management is required in computer?
vi. Differentiate between process and thread.
vii. Why protection system is required in a computer?
SECTION – C
Q#1: Describe any four (4) functions of operating system.
Q#2: Describe the five states of process with diagram.
Q#3: Describe any four (4) operating system in term of interface.
Prepared By: RIZWAN MIRZA
XII NOTES COMPUTER
CHAPTER# 2 SDLC
1. Enhancement, upgradation, and bug fixation are done during the______ step in the SDLC.
A. Maintenance and evolution C. D o c u m e n t at i o n
B. Problem identification D. Design
2. Entities having a positive or negative influence in the project completion are known as:
A. Stake Holders C. Stake Supervisor
B. Stake Owner D. Stake Person
3. Organized process or set of steps that need to be followed to develop an information system:
A. Analytical Cycle C. SDLC
B. Design Cycle D. P r o g r a m S p e c i f i c a t i o n
4. System maintenance is performed in response to ___________:
A. User Requirements Change C. Technology Change
B. Business Requirements D. P r o b l e m Id e n t i f i c a t i o n
5. The ---------- determines whether the project should go forward.
C. Feasibility Study C. System Analysis
D. Requirement Engineering D. Design
6. ______ phase is also called the “Architectural” phase of SDLC.
C. Defining C. Designing
D. System Analysis D. Testing
7. ________spend most of their time in the beginning stages of the SDLC, talking with end-users
gathering requirements, documenting systems, and proposing solutions:
C. Programmer C. Tester
D. Data Manager D. System Analyst
8. A _________ is an individual organization that is currently are potential buyer of software.
C. Customer C. Manager
D. Software Tester D. Programmer
9. In flowchart Input/output operation is represented by______:
A. Arrows C. Rectangle
B. Parallelogram D. Diamond
SECTION – B
i. How functional and non-functional requirements are different from each other?
ii. Explain flow chart symbols.
iii. Why feasibility study is necessary before starting a project?
iv. Define Stack Holders with examples.
v. Give some activities of the Planning Stage.
vi. Why system testing is important? Give three reasons.
vii. Write the importance of SDLC in software engineering.
viii. Differentiate between flowchart and algorithm.
ix. Write the responsibilities of a Project Manager.
x. Which activities are performed in Implementation phase?
SECTION – C
Q#1: What is the purpose of Requirement Engineering Phase? Explain its various steps.
Q#2: Which personnel are involved in SDLC? Explain their roles. (any three).
Q#3: What is the purpose of Conversion in SDLC? Explain its various stages.
Q#4: What is System? Explain the activities of Planning and Development phases.

Prepared By: RIZWAN MIRZA


XII NOTES COMPUTER
CHAPTER# 3 OOP in C++
Sr no. Question A B C D A B C D
Which of the following is
i. ignored during program Variables Comments Constants Keywords
execution?

In C++ the expression


ii. sum=sum+n; sum+=sum sum=+n sum+=n sum=+sum

The number of bytes


iii. reserved by float type 2 4 6 8
variable:
Which of the following is an
iv. arithmetic operator? > & % ++

Which of the following is a


v. not equal operator in C++? = != == =!

Which of the following is not


vi. a valid statement? \n \f \a \y

Relational operator allows


vii. you to ------------- numbers: Addition Compare Multiply Division

getch () function is belong to


viii. conio.h iostream.h math.h string.h
_________ library file:
ix. cout<<17/3; is equal to: 5.55 5.00 5 5.66
SECTION – B
i. State that following variables are valid or invalid with reason.
(a) _Age (b) &Marks (c) First_Name (d) tot.al
ii. Define type casting with example.
iii. What is difference b/w getch () and getche ()?
iv. What will happen if you try to modify a const variable after declaration?
v. Differentiate between variable declare and initialize with the help of examples.
vi. What is difference b/w gets () and puts ()?
vii. Define Reserve Words. Write the name of any five (5) reserve words.
viii. Write a note on const qualifier.
ix. Differentiate between A=B++ and A=++B.
x. Write the output of the following:
(a) (a>b) &&(a>c) a=15, b=20, c=5
(b) (x+y==z) || (z>y) x=25, y=15, z=50
(c) ! (s+u+t==50) s=20, u=15, t=15
SECTION – C
Q#1: Write a note on basic structure of C++ program.

Q#2: Define endl and setw manipulators and give an example of each.

Q#3: Write a note on type casting with its types.

Prepared By: RIZWAN MIRZA


XII NOTES COMPUTER
CHAPTER# 4 CONTROL STRUCTURE
Sr
Question A B C D A B C D
No.
In a for loop, this expression is
i. executed only once: Condition Initialization Inc/dec None

There is a semicolon at the end


ii. of___________ statement? for loop while loop do-while loop All

Continuous
iii. While loop is also called: Counter loop Wend loop Conditional loop
loop
One execution of a loop structure
iv. is called: Cycle Duration Iteration Test

This statement causes a loop to


v. terminate early: continue exit break default

If statement condition always


vi. written in _______ parenthesis: Square Angle Curly Small

Which of the following can be


If-else If-else-if switch
vii. used to replace the ternary if statement
operator? statement statement statement

Which of the following is a valid


viii. If iF IF if
selection structure keyword in C?
Which of the following delimiters
ix. are used to create block of () {} [] <>
statements?

SECTION – B
i. Differentiate between break statement and exit function.
ii. Write the purpose of default statement in switch statement.
iii. Write a program that inputs three numbers from user and displays the greater one.
iv. Write the purpose of break statement in switch statement.
v. Write a program to check if a character entered by the user is a vowel (a, e, i, o, u) or a consonant using an if-
else statement.
vi. Converts the following loop into do-while loop.
for (int n=10; n>=5; n--)
cout<<” ABICS”;
vii. Write a program to check if a number is divisible by both 5 and 11 using nested if statements.
viii. Display the output by using while loop:
3 5 7 9 11 13 15 17 19 21
SECTION – C
Q#1: Write a program to perform basic arithmetic operations (+, -, *, /) based on user input using a switch
statement.
Q#2: Write the nested loop that will print the following pattern:
1 2 3 4 5
1 2 3 4
1 2 3
1 2
1

Prepared By: RIZWAN MIRZA


XII NOTES COMPUTER
CHAPTER# 5 ARRAYS AND STRINGS
Sr
Question A B C D A B C D
No.
Which of the following identifies
i. the last element of array declared A [0][0]; A [7][6]; A [6][7]; A [7][7];
ad int A [8][7]?

Which of the following identifies


ii. the first element in array named Temp {0} Temp [0] Temp [1] Temp {1}
Temp?

What will be the output of the


following code?
iii. 1 2 3 4
int arr[5] = {1, 2, 3, 4, 5};
cout<<arr[3];
If an array is declared as int arr[5]
iv. = {1, 2};, what will be the value of 0 1 2 Garbage Value
arr[4]?
How do you declare a 2D array
v. with 3 rows and 4 columns? int arr[3,4]; int arr[3],[4]; int arr[3][4]; int arr[4][3];

Which of the following functions is


vi. used to append a string onto the strcpy() strcmp() strlen() strcat()
end of another string?

The string compare function it will


vii. return ---- if string 1 and string 2 +1 -1 1 0
are same:

What is the maximum size of a Unlimited


viii. 19 Characters 20 Characters 21 Characters
string char str [20]? Characters
Which header file is required to
ix. use C++ string functions like <iostream.h> <stdio.h> <string.h> <math.h>
strcmp(), strcpy(), and strlen()?

SECTION – B
i. Declare an array named x that has 5 rows and 3 columns and assign it values from 1-15 in the declaration
statement.
ii. Differentiate between array size and array indexes.
iii. What are subscripts in an array? Draw graphically.
iv. Can we start array index with other number than zero? Justify (yes or no).
v. Differentiate b/w strcmp() and strcat().
vi. What is advantage of using cin.get () function over cin statement for reading string?
vii. For the given array:int Arr[10]={5,6,99,5,32,12,5,89,65,5};
write a program that prints the number of times the number 5 appears in the array.
viii. Write a program that reads two string, copies it into another string and then prints both strings.
ix. Differentiate b/w strcat() and strcpy().
x. Write a program that reads two string and then prints the length of both strings.
SECTION – C
Q#1: Write a program that reads 3 strings and prints the smallest.
Q#2: Write a program that print sum of an array that has size 10 (20,30,40,5,4,6,7,8,10,19).
Q#3: Write a program that prints the given array in reverse order: (20,30,40,5,4,6,7,8,10,19).

Prepared By: RIZWAN MIRZA


XII NOTES COMPUTER
CHAPTER# 6 FUNCTIONS
Sr
No Question A B C D A B C D
.
Those functions which are
defined inside the body of
i. another function are Local Global Defined Inline
called_______function.
________should be used in the
ii. function body to return the break continue return exit
result to the calling program.
In passing arguments by
Double
iii. reference the original variable Colon Semicolon Ampersand
Quotation
should precede by:
Variable inside parenthesis of
iv. function declarations Universal Module Local Global
have_________level access
Argument of a functions are
v. separated with_______: Brackets Comma Colon Semicolon

We declare function with


vi. _______ if it does not have int float char void
any return type:
sqrt function belongs to
vii. _______ library file: math cmath string conio

Where does the execution of


main function user define void function else function
viii. the program start?
return type,
What are mandatory parts in return type, return type, function function name,
ix. the function declaration?
function name parameters name, parameters
parameters
SECTION – B
i. Explain function components with example.
ii. Define default arguments with example.
iii. Explain the scope of different types of variables used in functions.
iv. What is meant by function overloading? Write its advantages.
v. Write a program with a function named EvenOdd to read a number from the user and print it’s even or odd.
vi. Describe actual and formal parameters with the help of example.
vii. Write program with a function named LeapYear to read a number from the user and print it’s leap year or not.
SECTION – C
Q#1: Write a C++ program to read a number from a user and then pass it to a function to display its table.
Q#2: Describe different commonly used methods of passing arguments to a function.
Q#3: Write a C++ program having two functions names “area” and “perimeter” to find the area and perimeter of
a square.
Q#4: Write a program with a function name “mean” to read in three integers from the keyboard to find the arithmetic
mean.

Prepared By: RIZWAN MIRZA


XII NOTES COMPUTER
CHAPTER# 7 POINTERS
Sr no. Question A B C D A B C D
What is the correct syntax for
i. declaring a pointer variable in int ptr; int *ptr; int ptr*; int &ptr;
C++?

Which operator is used to get


ii. the address of a variable? * & #
%
Which operator is used to
iii. access the value stored at a & * ^ $
pointer’s address?
int a = 5;

iv. int *ptr = &a; 5 Address of a Address of ptr Error


cout << ptr;

Which of the following is a


void ptr; void *ptr; int *ptr=void; *void ptr;
v. void pointer?
Which of the following
assigns the address of y to the p2=&y; *p2=&y; y=&p2; y=p2;
vi. pointer p2;

What does int **ptr; A double A function An array


A void pointer
vii. represent? pointer pointer pointer
Both ptr and
What is the purpose of const Compilation
viii. ptr is constant *ptr is constant *ptr are
int *ptr;? error
constant
What does a pointer store? A memory
ix. A value A data type A function
address
SECTION – B
i. What is a pointer? Describe the advantages of pointer variable.
ii. How pointer variable is different from simple variable?
iii. Differentiate between reference and de-reference operators with the help of examples.
iv. How pointer is initialized? Write a simple program to illustrate this concept.
v. How does a void* pointer differ from other pointer types, and when would you use it?
vi. Differentiate between cout<<*p and cout<<p, if p is a pointer.
vii. Write down purpose of asterisk (*) in the following statement:
a. f=m*a b. float *b=&a; c. *b=200;
SECTION – C
Q#1: Write a C++ program in which declare and initialize a pointer to an integer and print its value
and address.
Q#2: Write a C++ program in which declare 3 variables with int, float and char, and store their
addresses in void pointer.

Prepared By: RIZWAN MIRZA


XII NOTES COMPUTER
CHAPTER# 8+9 OBJECTS AND CLASSES + FILE HANDLING
1. A text file has the extension ________
A. .doc C. .txt
B. .text D. .docx
2. ______ is the collection of bytes.
A. Text file C. Character file
B. Binary file D. Document file
3. Default mode parameter for ofstream is_________:
A. ios::in C. ios::out
B. ios::binary D. both a & b
4. The classes ifstream, ofstream and fstream are defined in:
A. iostream.h C. fstream.h
B. conio.h D. ifstream.h
5. A class is a user-defined data type which has data members and ______:
A. Data function C. Member Function
B. Variable D. Linear Function
6. The data members in the class C++ program are by default:
A. Protected C. Public
B. Private D. Virtual
7. A constructor has the same _______ as a class:
A. Variable C. Object
B. Function D. Name
8. The name of the destructor is always preceded by the symbol:
A. * C. &
B. ~ D. %
9. _____ means multiple possible states for a single property:
A. Inheritance B. Abstraction
B. Polymorphism D. Data Hiding
10. Which operator is used to mark the end of the class:
A. & B. ;
B. “ “ D. @
SECTION – B
i. Write the differences between private and public access specifiers.
ii. Define polymorphism with real-life example.
iii. Write a C++ program implementing inheritance between Animal (base class) and Cat (derived class).
iv. How data members can be accessed? Explain with the help of an example.
v. Explain bof() and eof() functions and their purpose.
vi. Write the purpose of ifstream and ofstream In the File Handling.
vii. Write a C++ program to write the message” This is a program that tells you how to write to a file” .
viii. Differentiate between constructor and destructor with example.
ix. Explain Classes and Objects with example.
x. Differentiate between text and binary file.
SECTION – C
Q#1: Write a C++ program implementing a class with the name Circle having two functions with the name; GetRadius and
CalArea. The functions should get the value for the radius from the user and then calculate the area of the circle and display the
results.
Q#2: Describe different modes of opening files and their description.
Q#3: Write a C++ program that have a class named “Employee” and calculate the salary of employee with following conditions:
i.Two private data members employeeID and basicSalary.
ii.Member function CalculateSalary().
Prepared By: RIZWAN MIRZA

You might also like