Programming Quiz (6)
1 . In array items, which of the following expressions will retrieve the value at row 3 and column 5?
A. items( 3 ).( 5 )
B. items( 3( 5 ) )
C. items( 3 )( 5 )
D. items( 3, 5 )
2. The number in parentheses after an array name is the __________ of the item in the array.
A. value
B. position
C. size
D. length
3. What is the proper For Each...Next header format?
A. For Each Type in arrayName
B. For Each arrayName
C. For Each type_identifer As Type In arrayName
D. For Each Type
4. Consider the code below:
Dim a(9) As Integer
For i As Integer = 0 To a.Length - 1
a(i) = i + 2
Next
Dim result As Integer = 0
For i As Integer = 0 To a.Length - 1
result += a(i)
Next
The value of variable result will be __________.
A. 62
B. 64
C. 65
D. 67
5. Which of the following correctly accesses element 13 of array Book?
A. Book(0) + 13
B. Book(13)
C. Book[13]
D. (13)Book
6. Consider the code below:
Dim a() As Integer = {99, 22, 11, 3, 11, 55, 44, 88, 2, -3}
Dim result As Integer = 0
For i As Integer = 0 To a.Length - 1
If a(i) > 30 Then
result += a(i)
End If
Next
The value of variable result will be __________.
A. 280
B. 154
C. 286
D. 332
12 years ago
5
Purchase the answer to view it

- FIN 571 Week 6 Final ( FIN571 Week 6 Finals EXAM MCQ ) FIN/571 Week 6 Final Exam Quiz
- INF 231 Week 5 Discussion 1 Input and Output 1#
- CJA 413 Week 5 Final -- Ethical Scrapbook Project
- CGD 318 Week 1 DQ 2 Public Relations and Crisis Management
- ACC 497 Week 3 Learning Team Case Study Assignment
- POS 421 - Week 5 -- DQ 2
- HSM 230 Week 9, Capstone CheckPoint
- COM 285 -- Employee Privacy Report
- ACC 422 Week 3 DQ 1 and DQ 2
- ACC 290 Week 1-5 Entire Course A++ 100%