0% found this document useful (0 votes)
11 views

Unsolved MCQs

This document appears to be a test paper for a computer science class assessing knowledge of programming structures like selection and decision making statements. It contains multiple choice questions, true/false questions, and fill in the blank questions testing understanding of concepts like: - Control structures like sequence, selection, and repetition - Decision making statements like if, if-else, nested if, switch - Logical and relational operators - The ternary conditional operator - Flowcharts and their use in representing program logic The test covers key concepts for understanding selection and decision making in programming.

Uploaded by

Romi Awan
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
11 views

Unsolved MCQs

This document appears to be a test paper for a computer science class assessing knowledge of programming structures like selection and decision making statements. It contains multiple choice questions, true/false questions, and fill in the blank questions testing understanding of concepts like: - Control structures like sequence, selection, and repetition - Decision making statements like if, if-else, nested if, switch - Logical and relational operators - The ternary conditional operator - Flowcharts and their use in representing program logic The test covers key concepts for understanding selection and decision making in programming.

Uploaded by

Romi Awan
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

Smart Guess & Test Papers

Student Name ______________________ Father Name ______________________ Roll Number _______


Class: 2nd /Year - Computer Science New Marks : 39 Exam Format : Chapter Wise MCQs
Time : notespk.com_Nauman Sadaf | Date _________________ Examiner Sig __________ Chapter#: 11

MCQ's S/Q L/Q Total

Objective Type

1. Encircle the Correct Option. (1 x 24 = 24)


1) Which programming structure executes program statements in order ?
a) Relation b) Decision c) Sequence d) Repetition

2) Another term for computer making a decision is .


a) sequuential b) Selection c) Repetition d) Iteration

3) ____ structure are used to control the flow of execution in a program .


a) Data b) Program c) Input d) Control

4) Which one is a control structure ?


a) Selection b) Sequence c) Repetition d) All of these

5) A ____ structure chooses which statement or a block of statements is to execute .


a) Selection b) Input / output c) Sequence d) Repetition
6) ____ structures is a selection structure ?
a) if b) if - else c) switch d) All of these

7) A group of statements enclosed in opening and closing braces is called .


a) Group statement b) Program statement c) Compound statement d) All of above

8) In if-statement , true is represented by .


a) 1 b) 2 c) 3

9) In if-statement , false represented by .


a) 2 b) 1 c) 3

10) In if statement , normally true is represented by .


a) 1 b) 2 c) 3

11) Graphical representation of a program is called.


a) Flowchart b) Logical chart c) Binary chart d) Logical diagram

12) Which statement is used for making two way decision ?


a) if b) Nested if c) While d) if-else

13) Which expression can be used in if condition ?


a) Relational b) Logical c) Arithmetic d) All of these

14) An if statement inside the true block of another if statement is called .


a) Nested if statement b) Conditional operator c) Branched if statement d) Relational operator

15) In if-else if statement only ______ block (s) of statement is executed .


a) One b) Two c) Three d) More than three

16) How many logical operators are available in C language .


a) 2 b) 3 c) 4 d) 5
17) The conditional operator is used as alternate to .
a) if b) if - else c) if - else if - else d) switch

18) Term for conditional operator is .


a) Ternary b) Binary c) Byte d) Iteration

19) Conditional operator takes .


a) One operand b) Two operand c) Three operand d) Four operand

20) Which operator is called ternary operator ?


a) If b) ++ c) ? d) ( )

21) What will be the output of ( 7 > 8 ) ? printf ("ABC"):printf("XYZ");


a) ABC b) XYZ c) ABCXYZ d) All of these

22) If x = 2 and y = 3 , what will be the output of the expression ? x>y? x + y : x*y;
a) 6 b) 5 c) 12 d) 10
23) If a = 5 and b = 10 , what the output of the following expression ? a>b? a*b: a+b;
a) 5 b) 150 c) 100 d) 15

24) ______ is not decision making statement .


a) if b) break c) nested if d) switch
2. Write "T" for a true statement and "F" for a false statement (1 x 7 = 7)
25) An arithmetic expression cannot be used as condition in if statement .
☐ True ☐ False

26) The condition operator is a ternary operator .


☐ True ☐ False

27) Logical operators are used to compare values .


☐ True ☐ False

28) In sequence structure , statements are executed in the same order in which they appear in the program .
☐ True ☐ False

29) A false condition always evaluates to zero .


☐ True ☐ False

30) Use of the statement terminator at the end of an if statement causes a syntax error .
☐ True ☐ False
31) C is an unstructured programming language .
☐ True ☐ False

3. Fill in the blanks. (1 x 8 = 8)


32) __________ controla the flow of execution in a program .

33) _________ is a group statements enclosed in braces .

34) If statement is used to select a pathflow in a program based on a __________

35) A ___________ is a pictorial representation of a program .

36) ________ refers to a structure with one if statement inside another if statements .

37) ________ statement can be used as an alternative to if-else if statement .

38) The purpose of ________ label in switch-case statement is the same as that of else in if-else statement .
39) A condition is an expression that is either ______________ or ___________ .

You might also like