Which of the following code segments will copy the values of a 5 element array named intOldValues into another 5 element array named intNewValues?
A) intIndex = 1 Do While intIndex < =5
IntNewValues(intIndex) = intOldValues(intIndex)
IntIndex = intIndex + 1
Loop
B) intIndex = 0 Do While intIndex < 5
IntNewValues(intIndex) = intOldValues(intIndex)
IntIndex = intIndex + 1
Loop
C) For intIndex = 1 To 5 intNewValues(intIndex) = intOldValues(intIndex)
Next intIndex
D) For intIndex = 0 To 4 intOldValues(intIndex) = intNewValues(intIndex)
Next intIndex
Correct Answer:
Verified
Q5: Which of the following statements sorts an
Q6: Which of the following allows an application
Q7: Which statement is the best solution for
Q8: The lowest possible subscript of an array
Q9: What is the error in the following
Q11: When changing the number of elements in
Q12: Which of the following provides the index
Q13: Which of the following statements defines a
Q14: What task is accomplished by the following
Q15: Assume that an integer array named intValues
Unlock this Answer For Free Now!
View this answer and more for free by performing one of the following actions
Scan the QR code to install the App and get 2 free unlocks
Unlock quizzes for free by uploading documents