What is the output of the following code, if the user enters the sequence 10 17 35 7?
const int MAX = 4;
int items[MAX];
for (int i = 0; i < MAX; i++)
cin >> items[i];
items[2] += 2;
for (int i = 0; i < MAX; i++)
cout << items[i] << “ “;
const int MAX = 4;
int items[MAX];
for (int i = 0; i < MAX; i++)
cin >> items[i];
items[2] += 2;
for (int i = 0; i < MAX; i++)
cout << items[i] << “ “;
const int MAX = 4;
int items[MAX];
for (int i = 0; i < MAX; i++)
cin >> items[i];
items[2] += 2;
for (int i = 0; i < MAX; i++)
cout << items[i] << “ “;
a) 12 19 37 9
b) 10 2 35 7
c) 10 17 37 7
d) 10 19 35 7
b) 10 2 35 7
You might also like to view...
The device needed to connect two or more networks together is called a(n) ________
a.access point b.modem c.optical network terminal d.router
Three types of loop statements can be used to iterate through an array.
Answer the following statement true (T) or false (F)