Collections can be broken down into two types linear and seq

Collections can be broken down into two types linear and sequential linear and nonlinear hierarchical and sequential Arrays and Array Lists All arrays are objects of the base type _____ class. Super Array Object Base Given an array declared to hold 100 values, the largest index that can be used with the array is: 101 99 100 undetermined If an array named num is dimensioned to hold 10 values, how would you store 11 in the 3rd physical location? num[3] = 11; num[2] = 11; num = 50[4] num3 = 11; int [] anArray = {86, 66, 76, 92, 95, 88}; for (int i = anArray.Length-1; i > -1; i--) {total += anArray[i];} Using the declaration above for an Array, what is added to total during the first iteration? 0 86, 66, 76, 92 and 95 88 unknown, because i is not initialized Which of the following could be a method heading for a member method that returns an array? int [] void DoSomething() int [] DoSomething() void int [] DoSomething() void DoSomething[] If an array is to be sent to a method, which of the following is a valid heading for a method? void DisplayOutput(double [] anArray) void DisplayOutput(double anArray) void DisplayOutput(double [10] anArray) void DisplayOutput(double anArray [10]) Which of the following is a valid example of calling a method and sending it an array argument? DisplayArrayContents(int [] anArray); DisplayArrayContents(anArray[10]); DisplayArrayContents(anArray); DisplayArrayContents(int [10] anArray); If you do not know the size of the array needed, you can create an array large enough to hold any entries and tell users to enter a predetermined sentinel value after they enter the last value. Using this approach: requires that you increment a counter as values are entered so that you know how many elements are stored in your array is preferred to defining a static sized array. requires that you dimension the array to hold at least 100 entries. requires the array be defined to hold string elements.

Solution

Hi, I have answered first 5 questions.

Please repost others on separate post.

Please let me know in case of any issue in first 5.

Q1.
Collection can be divided into two parts:
linear and non-linear

List is linear collection
Set, Map are non-linear

Q2.
Ans: a. Object

Object class is the baase class of all other classes in Java

Q3.
Ans: b. 99
Array index starts from 0 to n-1, n is the size of an array

Q4. Ans: b. num[2] = 11
index of third element is (3-1) = 2

Q5.
Ans: b. 88

Loop starts from i = anArray.length-1 = 5, and anArray[5] = 88

 Collections can be broken down into two types linear and sequential linear and nonlinear hierarchical and sequential Arrays and Array Lists All arrays are obje

Get Help Now

Submit a Take Down Notice

Tutor
Tutor: Dr Jack
Most rated tutor on our site