- If an
If
statement contains three or more conditions connected with both
and
&
or
, how are the conditions connected?
- Conditions in parentheses are connected first, then conditions around
and
and finally conditions around
or
.
- Conditions in parentheses are connected first, then conditions around
or
and finally conditions around
and
.
- Conditions are connected in the order that they are coded.
- Three or more conditions in an
if
instruction is not supported in Visualbasic.
- None of the above--------------------------------------------------------------
Which of the following is not allowed in the coding of a decision operation?
Or
And
Not
- All of the above are legal
- None of the above is legal----------------------------------------------------------
Which type of looping structure is best to use when the number of loop repetitions is known?
Do While
loop
Do Until
For Next
- Boolean loop
- None of the above
- ----------------------------------
Which type of looping structure is generally used when the number of loop repetitions is not known?
Do While loop
Do Until loop
For Next
- Either a or b
- None of the above
-----------------------------
- If the step value is positive, a
For Next
loop terminates when:
- The loop variable is greater than or equal to the stop value
- The loop variable is less than or equal to the stop value
- The loop variable is greater than the stop value
- The loop variable is less than the stop value
- None of the above
- If the step value is negative, a
For Next
loop continues to execute as long as:
- The loop variable is greater than or equal to the stop value
- The loop variable is less than or equal to the stop value
- The loop variable is greater than the stop value
- The loop variable is less than the stop value
- None of the above
Which of the following is mandatory in the coding of the arguments for a
For Next
loop?
- Start value
- Stop value
- Step value
- Both a and b
- All of the above
- What is the value of the following expression:
9 * 2 - 8 > 5 + 2 / 2
?
- 10
- 6
- True
- False
- None of the above
Which of the following programming concepts relates to situations where part of the programming specifications requires a determination of the number of times an activity in the program execution is occurring?
- Accumulators
- Input validation
- Counters
- Sequencing
- None of the above
If the intQuantity and decPrice variables contain the numbers 3 and 15.75, respectively, the condition
If intQuantity > 0 And intQuantity < 10="" or="" decprice=""> 20
will evaluate to:
- True
- False
- It cannot be determined
- An error would be generated by this statement
- None of the above
Which of the following has the most limited scope?
- A variable declared at the beginning of a procedure
- A variable declared in a
For Next
loop
- A static variable declared at the beginning of a procedure
- A class level variable
- None of the above
Which of the following describes a nested
If
?
- An
if
inside a
do
while
loop
- An
if
inside a
For Next
loop
- An
if
inside an
if
- An
if
without an
else
- None of the above
Which of the following is the line continuation character?
- \ - backslash
- - hyphen
- _ underscore
- # hash symbol
- None of the above
To prevent a text box from accepting inappropriate characters, you first use the e parameter’s ____ property to determine the key that the user pressed.
- KeyDown
- KeyEnter
- KeyChar
- KeyPress
- None Of the above
- What type of variable is x after the following statement is executed?
x = 9 * 2 - 8 > 5 + 2 / 2
- Double
- Integer
- Decimal
- String
- None of the above
Which of the following conditions will evaluate to True when the intPackages variable contains the value 100?
If intPackages = 100
If intPackages <> 0
If intPackages > 1
- All of the above
- None of the above
Which of the following statements assigns the contents of the txtGrade control, in uppercase, to the strGrade variable?
If strGrade = txtGrade.Text.ToUpper Then
ToUpper = txtGrade.Text
strGrade = txtGrade.Text.ToUpper
Text.ToUpper = strGrade
- none of the above
You can use a(n) ____ to visually separate related controls from other controls on the form.
- Radio button
- Check box
- Group box
- Icon area
- None of the above
A control’s ____ event occurs each time the user presses a key while the control has the focus.
- PressEnter
- KeyEnter
- KeyPress
- GotFocus
- None of the above
The number of choices the user can select from a list box is controlled by the list box’s ____ property.
- SelectionCount
- SelectionControl
- SelectionMode
- SelectionIndex
- None of the above
If the
stepValue
is omitted when coding a
..Next
statement, the
stepValue
is ____ at execution time.
- -1
- 0
- The step value will not be assigned as the loop will not execute and control will flow to the statement following the loop
- An error will be generated and the program will abnormally terminate
- None of the above
When you pass a variable
____, the computer passes only the value of the variable to the receiving procedure.
- By reference
- By parameter
- By argument
- By datatype
- None of the above
Which of the following is a valid Return statement?
dblNumber return
return dblNumber ByRef
return ByRef dblNumber
return dblNumber
- none of the above