Exam 3: More Flow of Control
Exam 1: Introduction to Computer and C Programming55 Questions
Exam 2: C++ Basics54 Questions
Exam 3: More Flow of Control44 Questions
Exam 4: Procedural Abstraction and Functions That Return a Value51 Questions
Exam 5: Functions for All Sub Tasks53 Questions
Exam 6: Io Streams As an Introduction to Objects and Classes51 Questions
Exam 7: Arrays34 Questions
Exam 8: Strings and Vectors63 Questions
Exam 9: Pointers and Dynamic Arrays40 Questions
Exam 10: Defining Classes50 Questions
Exam 11: Friends, overloaded Operators, and Arrays in Classes49 Questions
Exam 12: Separate Compilation and Namespaces38 Questions
Exam 13: Pointers and Linked Lists51 Questions
Exam 14: Recursion43 Questions
Exam 15: Inheritance53 Questions
Exam 16: Exception Handling47 Questions
Exam 17: Templates33 Questions
Exam 18: Standard Template Library57 Questions
Select questions type
Variables defined inside a set of braces are said to be _______ to that block of code.
(Short Answer)
4.7/5
(33)
The code following the ________ case is executed if none of the other cases are matched in a switch statement.
(Short Answer)
4.9/5
(32)
What is the value of the following expression?
True && 4/3 || !6)))
(Multiple Choice)
4.9/5
(32)
In an enumerated data type,different constants may not have the same value.
(True/False)
4.8/5
(28)
All nested if-else statements can be converted into switch statements.
(True/False)
4.9/5
(30)
What is the output of the following code fragment?
{
Int x=13;
Cout << x <<",";
}
Cout << x << endl;
(Multiple Choice)
4.8/5
(36)
A compound statement that contains variable declarations is called a __________.
(Short Answer)
4.9/5
(30)
Given the following enumerated data type definition,what is the value of SAT?
Enum myType{SUN,MON,TUE,WED,THUR,FRI,SAT,NumDays};
(Multiple Choice)
4.7/5
(30)
If you want a loop to quit iterating if x < 10 and y > 3,what would be the proper loop condition test?
(Multiple Choice)
4.7/5
(40)
What is the value of x after the following code executes?
Int x=10;
Ifx++ >10)
{
X =13;
}
(Multiple Choice)
4.9/5
(37)
What is wrong with the following switch statement?
Int ans;
Cout <<"Type y for yes on n for no\n";
Cin >> ans;
Switch ans)
{
Case 'y':
Case 'Y': cout << "You said yes\n"; break;
Case 'n':
Case 'N': cout << "You said no\n"; break;
Default: cout <<"invalid answer\n";
}
(Multiple Choice)
4.9/5
(48)
Which boolean operation is described by the following table?


(Multiple Choice)
4.8/5
(29)
A loop that iterates one too many or one too few times is said to be ________
(Short Answer)
4.8/5
(42)
All switch statements can be converted into nested if-else statements
(True/False)
4.8/5
(30)
What is the output of the following code fragment if x is 15?
Ifx < 20)
Ifx <10)
Cout << "less than 10 ";
Else
Cout << "large\n";
(Multiple Choice)
4.7/5
(40)
Showing 21 - 40 of 44
Filters
- Essay(0)
- Multiple Choice(0)
- Short Answer(0)
- True False(0)
- Matching(0)