ethanspencer8254 ethanspencer8254
  • 18-07-2019
  • Computers and Technology
contestada

int alpha [5];

int j;
alpha [0] = 2
for ( j = 1; j < 5; j++)
alpha [j] = alpha [ j - 1] + 3;
3. What is the value ofalpha[4] after the code aboveexecutes?

a.

5

c.

11

b.

8

d.

14

Respuesta :

demimurray573
demimurray573 demimurray573
  • 28-07-2019

Answer:

D - 14

Explanation:

Each time the program executes an iteration of the for-loop, it works out the current element by adding 3 to the previous element.

alpha[0] = 2

+3

alpha[1] = 5

+3

alpha[2] = 8

+3

alpha[3] = 11

+3

alpha[4] = 14

Answer Link

Otras preguntas

Un automovil recorre 80 km en 45 minutos. cuantos kilometros recorrera en dos horas?
4y+x=15 x=8y+3? Elimination Graphing Consistent’ Substitution
Type the correct answer in each box. O O -7 6 5 4 3 -2 -1 9 5 2 32 + 2 3 4 9 9 2 O w. 4 The reflection of point S across the y-axis is point coordinates are ( 5
What is the difference between 5,198 and 8,250
an open-top storage bin in the shape of rectangular prism whose base is a square constructed such that the volume is 3500 cm^3. to minimize the weight of the st
Computer A has a processor speed of 5 x 10^9 cycles per second. Computer B has a processor speed of 2 × 10^8 cycles per second. How many times faster is compute
How do you think a soviet astronaut would have viewed the apollo 11 mission as it was taking place? support your answer.
the maximum fine for a first non-driving alcohol-related offense of possession or consumption of
Can someone help me on this?
234 Ca undergoes alpha decay 94