Home Virtual University CS201 Quiz – CS201 Introduction to Programming Solved Quiz

CS201 Quiz – CS201 Introduction to Programming Solved Quiz

by Usman CB
CS201 Introduction to Programming Solved Quiz

Are you still looking for CS201 Quiz – CS201 Introduction to Programming Solved Quiz? If yes then congratulations because we are here to offer you CS201 Quiz – CS201 Introduction to Programming Solved Quiz as well as their exact answer that will really help you in your mid term of Cs201 as well as will help in getting good marks in quiz.

CS201 Quiz – CS201 Introduction to Programming Solved Quiz

Question # 1
< and > both are _________ operators.
Arithmetic
Relational
Logical 
Mathematical

Question # 2 


Find out the logical error in following lines

of code. If (x = 10) cout “x is 10”;


10 should be enclosed in quotations
There is no semicolon at the end of if condition
Assignment operator should not be used for Comparison 
Variable x should not be inside parenthesis

Question # 3

 
What will be the result of the expression

j = i++; if initially j = 0 and i = 5?


0
5
6
4

Question # 4 


Default mechanism of calling a function by passing it array is call by ________ and in case of passing variable is call by ___.


Reference, Reference
Reference, value  

Value, Reference
Value, Value


Question # 5 

          
When the break statement is encountered in a loop’s body, it transfers the control

________from the current loop.


Inside

Outside

To break statement
To continue statement

Question # 6


________statement is used to terminate the processing of a particular case and exit

from switch structure.


If
Goto
Break
Continue

Question # 7

If we pass more than one arguments to a function then they are separated by____.

Comma, Lecture 9

Semicolon; 

Colon:

Brackets ()


Question # 8 


What will be the value of the variable output in the given piece of code?

double output = 0; output = (2 + 2) * 4 + 2 / (4 – 2); 


15
17
 12
 1

Question # 9 


If we assign 2.06721 to an integer variable x, what will be the output if we print x using cout statement? 


2 
2.1
2.06
2.07

Question # 10 


__________ will be used for clarity and to force the order of evaluation in an expression. 
 ” “
() PG32
 ‘ ‘
 [ ]  

Question # 11 


What will be the size of following array? int arr[29];


0

30 PAGE 105-106

29

28

Question # 12

If a function has not been declared before its definition, It is logical error

syntax error LECTURE NO 9
logical Error
run time error
none of these

Question # 13

When the break statement is encountered in a loop‟s body, it transfers the control from

the current loop.

Inside 

Outside By using break the loop will terminate.

To break statement 

To continue statement

Question # 14

When we access a multidimensional array, each array index is surrounded by_.

Single quotes ‘ ‘ 

Double quotes ” ” 

Brackets[] Lecture 11

None of the given

Question # 15

char name [] = “Hello World” ; In the above statement, a memory of ____characters

will be allocated

12 Lecture 12

10

11

13

Question # 16

A variable declared within a code block becomes variable for that block.

Static

Integer

Local Lecture 9

Global

Question # 17

When the, if statement consists of more than one statement then enclosing these statement

in braces, is _________. 


Compulsory 
Optional
Not required
Relevant

Question # 18

Characters of a string stored in an array can be accessed directly using array.

Manipulation

Superscript

Subscript Page No 123

Postscript

Question # 19

A variable declared within a code block becomes variable for that block.

Static

Integer

Local Lecture 9

Global

Question # 20

The data type before a function name represents its,

Return Type

Function data 

Function arguments

Function name

Download CS201 Quiz – CS201 Introduction to Programming Solved Quiz

You can download file by clicking;

You can Also Get Answer for Following:

cs201 solved mcqs mega file

cs201 lecture wise mcqs

cs201 mcqs solved

cs201 grand quiz mega file

cs201 quiz file

cs201 introduction to programming solved paper

cs201 current paper 2022

Related Posts

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.