Question need in C++. Question need in C++. We are learning arrays. No DO loops please. CMPSC 101 LAB 13 – Fun with arrays Write a program that reads 15 numbers (integers) from stdin, then displays the following: The total of the even numbered values (2nd value+ 4th value+ etc..) The total of the odd numbers (1st value + 3rd value + etc…) The total of every 5th number. Note that “even numbered values” mean the 2nd value, 4th value, etc., not “2”, “4”, “6”, etc. For example: The data is: 0,1,2,3,4,5,6,7,8,9,10,11,12,13,14 . No DO loops please. CMPSC 101 LAB 13 – Fun with arrays Write a program that reads 15 numbers (integers) from stdin, then displays the following: The total of the even numbered values (2nd value+ 4th value+ etc..) The total of the odd numbers (1st value + 3rd value + etc…) The total of every 5th number. Note that “even numbered values” mean the 2nd value, 4th value, etc., not “2”, “4”, “6”, etc. For example: The data is: 0,1,2,3,4,5,6,7,8,9,10,11,12,13,14
Question
need in C++. We are learning arrays. No DO loops please.
CMPSC 101 LAB 13 – Fun with
arrays
Write a program that reads 15 numbers (integers) from stdin, then displays the following:
The total of the even numbered values (2nd value+ 4th value+ etc..) The total of the odd numbers (1st value + 3rd value + etc…)
The total of every 5th number.
Note that “even numbered values” mean the 2nd value, 4th value, etc., not “2”, “4”, “6”, etc.
For example:
The data is:
0,1,2,3,4,5,6,7,8,9,10,11,12,13,14