Exam 7: Arrays and Lists

arrow
  • Select Tags
search iconSearch Question
flashcardsStudy Flashcards
  • Select Tags

A partially filled array is normally accompanied by an integer variable that indicates the number of items actually stored in the array.

(True/False)
4.8/5
(39)

Which one of the following statements assigns the value 40 to the first element in an array of integers named values?

(Multiple Choice)
5.0/5
(34)

Memory allocated for a reference type variable is the actual location that will hold any value assigned to the variable.

(True/False)
4.8/5
(32)

Because variables hold only single values, they can be cumbersome in programs that process lists of data.

(True/False)
4.9/5
(38)

An array's Length property is read-only, so you cannot change its value by trying to assign a new value to Length.

(True/False)
4.8/5
(35)

You access the individual elements in an array using their subscripts.

(True/False)
4.8/5
(42)

If you provide an initialization list when declaring an array, you can leave out the size declarator, but you cannot leave out the new operator and its subsequent expression.

(True/False)
5.0/5
(29)

When you process a(n) ____________, you must process only elements containing valid items.

(Multiple Choice)
4.8/5
(47)

Which one of the following statements correctly creates a List object named friendsList that holds strings?

(Multiple Choice)
4.8/5
(37)

Which one of the following assignment statements associates an int array, that can hold 12 integers, with a reference variable named scores?

(Multiple Choice)
4.8/5
(44)

You can store a variety of data types in an array.

(True/False)
4.8/5
(37)

The ____________ creates an object in memory and returns a reference to that object.

(Multiple Choice)
4.8/5
(37)

A(n) ____________ is an object that can hold a group of values that must all be the same data type.

(Multiple Choice)
4.9/5
(35)

Which one of the following statements correctly declares a reference variable named values that can be used to reference an array of int?

(Multiple Choice)
4.9/5
(34)

An array's size declarator must be a nonnegative integer value.

(True/False)
4.8/5
(33)

When a(n) ____________ variable is declared, the compiler sets aside, or allocates, a chunk of memory big enough to hold the variable's data.

(Multiple Choice)
4.8/5
(34)

____________ arrays, also known as 2D arrays, can hold two sets of data.

(Multiple Choice)
4.8/5
(31)

List objects, like arrays, are always passed to methods ____________.

(Multiple Choice)
4.8/5
(38)

A(n) ____________ is similar to a two-dimensional array, but the rows can have a different number of columns.

(Multiple Choice)
4.8/5
(43)

____________ arrays can only hold one set of data.

(Multiple Choice)
4.9/5
(29)
Showing 21 - 40 of 99
close modal

Filters

  • Essay(0)
  • Multiple Choice(0)
  • Short Answer(0)
  • True False(0)
  • Matching(0)