Exam 6: Repeating Instructions
Exam 1: Introduction to Computing and Programming75 Questions
Exam 2: Data Types and Expressions75 Questions
Exam 3: Methods and Behaviors75 Questions
Exam 4: Creating Your Own Classes75 Questions
Exam 5: Making Decisions75 Questions
Exam 6: Repeating Instructions75 Questions
Exam 7: Arrays75 Questions
Exam 8: Advanced Collections74 Questions
Exam 9: Introduction to Windows Programming75 Questions
Exam 10: Programming Based on Events75 Questions
Exam 11: Advanced Object-Oriented Programming Features75 Questions
Exam 12: Debugging and Handling Exceptions75 Questions
Exam 13: Working With Files75 Questions
Exam 14: Working With Databases75 Questions
Exam 15: Web-Based Applications73 Questions
Select questions type
9int sum = 0;
int number = 0;
while (number < 10)
{
sum = sum + number;
Console.WriteLine(sum);
}
The statement above prints the values of 0 through 9 on separate lines.
(True/False)
5.0/5
(43)
One of the major strengths of programming languages can be attributed to loops.
(True/False)
4.9/5
(37)
The _____________ method of the MessageBox class displays a predefined dialog box that can contain text, captions for the title bar, special buttons, and icons.
(Short Answer)
4.9/5
(34)
for (int i = 0; i < 5; i++) Console.Write(i + "\t");
The conditional expression used with the for statement ____.
(Multiple Choice)
4.9/5
(41)
Using the break or continue statements with a loop violates the single entry and single exit guideline for developing a loop.
(True/False)
5.0/5
(34)
s = num.Next(7);
The statement above produces seven random numbers.
(True/False)
4.8/5
(46)
In order to use the MessageBox.Show( ) method in your console application, you must ____.
(Multiple Choice)
4.8/5
(43)
An example for statement that has a compound initialization, compound test and compound update could be written as ____.
(Multiple Choice)
4.8/5
(28)
The conditional expression is sometimes called the loop condition.
(True/False)
5.0/5
(37)
An option other than looping that can be used to repeat program statement is _____________. With this technique a method calls itself repeatedly until it arrives at the solution.
(Short Answer)
5.0/5
(37)
Without incrementing the counter used in the conditional expression with counter controlled loops, the loop would go on indefinitely.
(True/False)
4.9/5
(40)
You must tell the user what value to type to end the loop for ____.
(Multiple Choice)
4.9/5
(29)
int sum = 0;
int number = 1;
while (number < 100)
{
sum = sum + number;
}
The program statements above produce an infinite loop.
(True/False)
4.8/5
(41)
Scope refers to the region in the program in which you can use the variable.
(True/False)
4.7/5
(27)
Class diagrams show the data, method, and property members of a class.
(True/False)
4.8/5
(41)
In order to use the MessageBox.Show( ) method, you need to not only add a reference to the namespace which includes the class, but also add a using directive to the program statements.
(True/False)
4.8/5
(33)
A state-controlled loop should be designed when you know the number of times the statements must be executed.
(True/False)
4.9/5
(33)
for (int i = 0; i < 10; i++) {
Console.WriteLine("counter " + i);
}
The variable i defined in the program segment above ____.
(Multiple Choice)
4.8/5
(37)
You often need to do a "prime the read" for counter controlled loops which means that you would input a value before going into the body of the loop.
(True/False)
4.7/5
(46)
Showing 41 - 60 of 75
Filters
- Essay(0)
- Multiple Choice(0)
- Short Answer(0)
- True False(0)
- Matching(0)