AlyssaHuling5506 AlyssaHuling5506
  • 04-07-2019
  • Computers and Technology
contestada

What will the following code print out: int numbers [] = {99, 87, . 66, 55, 101}; for (int i = 1; i < 4; i++) cout << numbers [i] << end1;a) 99 87 66 55 101 b) 87 66 55 101 c) 87 66 55 d) Nothing.

Respuesta :

PhantomWisdom PhantomWisdom
  • 14-07-2019

Answer:

87 66 55

Explanation:

Array is used o store the multiple values with same data type.

the array show a decimal value .66, i assume this is enter by mistake because option has no decimal value.

The index of the array is start from zero, it means the first element store in the array at position zero.

In the for loop the variable 'i' start from 1 not zero and it goes to i<4 means i=3.

So, it access the element from 2 to 4 because the index is position of element less than 1.

Therefore, 87 66 55 print.

Answer Link

Otras preguntas

Two spherical pieces of cookie dough have radii of 3cm & 5cm. The pieces are combined to form one large spherical piece of dough. What is the approximate ra
what is 66 2/3% of 39
Find the 10th partial sum of the summation of negative 5i plus 2, from i equals 1 to infinity.
the unit for energy is the
how you think the new values of your generation will affect economic decisions?
Solve please!!!!! need help!!!!!!!!!!!!!! y = 5x + 4
Check translation: Mi posesión más grande es mis perro. My greatest asset is my dog. Please explain if I made a mistake, thanks :D
write an equation for the line that is parallel to the given line and passes through the given point y=2x+4;(3,8)
Which best describes the underlined words in this sentence? (Could) she (have been baking) the cupcakes all afternoon? A. compound verb B. simple predica
what is an inequalite