option
My Daypo

C++

COMMENTS STADISTICS RECORDS
TAKE THE TEST
Title of test:
C++

Description:
MCQ Mid-term 15 ques

Author:
Dr.Abeer Moasaad
(Other tests from this author)

Creation Date:
14/01/2022

Category:
Others

Number of questions: 15
Share the Test:
Facebook
Twitter
Whatsapp
Share the Test:
Facebook
Twitter
Whatsapp
Last comments
No comments about this test.
Content:
1- What is decomposition? A- Ignoring unnecessary details in a problem B- Generalizing a problem so it can be solved more easily C- Breaking down complex problem or system into smaller more manageable sub-problems D- Prioritizing tasks within a program and determining the order in which to perform them.
2- Which of the following statement is NOT correct about flowchart? A- They never contain cycles that is you can never get to the same instruction twice by following the next instruction edge B- A parallelogram indicates a special type of instruction called an input/output instruction. C- Using diamond to direct the next instruction based on the value of some variable. D- If there is a directed edge from instruction 1 to instruction 2, then instruction 2 must be performed after instruction1.
3- Which of the following is correct about data representation and abstraction? A- Determine what data is required B- Breaking the problem into smaller sub problems C- Looking for pattern in the data D- All of the above.
4- Assuming the input list is not empty and text x and y are both initially 0. What is the output of this algorithm? A- The number of items in the list B- The average of non-negative numbers in the list C- The number of non-negative numbers in the list D- The sum of the non-negative numbers in the list.
5- Data representation and abstraction is the pinnacle of computational thinking A- True B- False.
6- What is the output of the following code? double x=25.8; cout<<”variable x is stored in “<<sizeof(x)<<” bytes\n”; return 0; A- Variable x is stored in 1 bytes B- Variable x is stored in 2 bytes C- Variable x is stored in 4 bytes D- Variable x is stored in 8 bytes.
7- What is the output of the following code? int a=6; int b=3; int c=4; double result; c-=2 result=3*(a-2)/double(b+5+c); cout<<result<<endl; A- 1 B- 1.2 C- 1.6 D- 0.75.
8- What is the output of the following code? int age=42; int experience=5; bool ispunished=false; bool is promoted=(age>35 && experience>=5 && !isPunished); cout<<isPromoted<<endl; A- 1 B- 0 C- True D- Flase.
9- The problem of cin.get() is that it skips over whitespace A- True B- False.
10- A single line comment in C++ language source code can begin with … A- ; B- /* C- // D- -.
11- Every C++ program must contain … A- Start() B- Main() C- System() D- Program().
12- Which header file is used to manipulate the string? A- Container B- iostream C- iomanip D- string.
13- Which operator is used for input stream? A- < B- << C- > D- >>.
14- The value 132.54 can be represented using which data type? A- Int B- Bool C- Double D- Char.
15- Which operator can be used to compose two values? A- == B- <> C- >< D- =.
Report abuse Terms of use
HOME
CREATE TEST
COMMENTS
STADISTICS
RECORDS
Author's Tests