adplus-dvertising
frame-decoration

Question

The strStates and strCapitals arrays are parallel arrays. If Illinois is stored in the second element in the strStates array, where is its capital (Springfield) stored?

a.

strCapitals(1)

b.

strCapitals(2)

c.

strCapitals(0)

d.

strCapitals(3)

Answer: (a).strCapitals(1)

Engage with the Community - Add Your Comment

Confused About the Answer? Ask for Details Here.

Know the Explanation? Add it Here.

Q. The strStates and strCapitals arrays are parallel arrays. If Illinois is stored in the second element in the strStates array, where is its capital (Springfield) stored?

Similar Questions

Discover Related MCQs

Q. If the elements in two arrays are related by their subscripts, the arrays are called as ________________ arrays.

Q. Which of the following assigns the string “Rover” to the fifth element in a one-dimensional array named strPetNames?

Q. Which of the following statements assigns (to the intElements variable) the number of elements contained in the intNums array?

Q. __________________ method is used to reverse the values.

Q. Arranging data in a specific order is called as ___________

Q. ________ method is used to sort an array in visual basic.

Q. The intSales array is declared as follows:

Dim intSales() As Integer = {10000, 12000, 900, 500, 20000}.

Which of the following loops will correctly add 100 to each array element? The intSub variable contains the number 0 before the loops are processed.

Q. The intNums array is declared as follows:

Dim intNums() As Integer = {10, 5, 7, 2}.

Which of the following blocks of code correctly calculates the average value stored in the array? The intTotal, intSub, and dblAvg variables contain the number 0 before the loops are processed.

Q. The intSales array is declared as follows:

Dim intSales() As Integer = {10000, 12000, 900, 500, 20000}.

Which of the following If clauses determines whether the intSub variable contains a valid subscript for the array?

Q. The strItems array is declared as follows:

Dim strItems(20) As String.

The intSub variable keeps track of the array subscripts and is initialized to 0. Which of the following Do clauses will process the loop instructions for each element in the array?

Q. The intSales array is declared as follows:

Dim intSales() As Integer = {10000, 12000, 900, 500, 20000}.

The statement intSales(3) = intSales(3) + 10 will

Q. Which of the following declares a five-element one-dimensional array?

Q. The _________ method returns an integer that represents the highest subscript in the specified dimension in the array.

Q. The act of initializing array is also called as _______

Q. If array is of String type all values are _________ by default.

Q. Data in an array can be distinguished using _______ number.

Q. Using array in a program is efficient because ________

Q. When you group together related variables, the group is referred to as _________

Q. A simple variable, also called as a ________ variable, is one that is unrelated to any other variable in memory.

Q. Each menu item should have an _______________ that is unique within its menu.