Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

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

image text in transcribed
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

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Beginning ASP.NET 2.0 And Databases

Authors: John Kauffman, Bradley Millington

1st Edition

0471781347, 978-0471781349

More Books

Students also viewed these Databases questions

Question

=+ What is the role of government in bargaining?

Answered: 1 week ago

Question

=+ Who is the negotiation partner at company level?

Answered: 1 week ago