Question: What is output by the code below? int tRay [ ] = { 2 , 1 2 , 1 1 , 4 5 , 5
What is output by the code below?
int tRay;
int big ;
forint i ; i; i
iftRayibig
big tRayi;
cout big;
Question options:
a
b
c
d
Question points
What operation is being performed by the method doTask
int doTaskint array int length
int z;
forint i; i
z;
return z;
Question options:
a
counting the numbers less than ten in array
b
counting all odd numbers in array
c
counting the numbers greater than ten in array
d
counting all even numbers in array
Question points
The array index can be any positive integer less than or equal to the array size.
Question options:
True
False
Question points
The base address of an array is the address that is the memory location of the last array element.
Question options:
True
False
Question points
Suppose that sales is an array of components of type double. Which of the following correctly initializes the array sales?
Question options:
a
for int j ; j ; j
salesj;
b
for int j ; j ; j
salesj;
c
for int ; j ; j
salesj;
d
for int j ; j ; j
salesj;
Question points
When you pass an array as a parameter, the base address of the actual array is passed to the formal parameter.
Question options:
True
False
Question points
The statement int list; declares list to be an array of components, since the array index starts at
Question options:
True
False
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
