subject
Engineering, 02.04.2020 15:57 Puppy9118

PLEASE CODE IN C++#include using namespace std;int main(){int array1[20] = {3, 18, 1, 25, 4, 7, 30, 9, 80, 16, 17};int numElements = 11;cout << "Part 1" << endl;// Part 1// Enter the statement to print the numbers in index 4 and index 9// put a space in between the two numberscout << endl;// Enter the statement to print the numbers 3 and 80 from the array above// put a space in between the two numberscout << endl;// Enter the statement to change the number 1 in the array to be 12// then write the statement to print out that number in the arraycout << "\nPart 2" << endl;// Part 2// Write a function called printAll. It takes in an array// and an integer that has the number of values in the array.// The function should print all the numbers in the array with// a space between each one.// Call the function on the line below. cout << "\nPart 3" << endl;// Part 3// Write a function called printEven. It takes in an array and// an integer that has the number of values in the array. It prints// all the even numbers in the array with a space between each one.// This function returns the count of evens. int evens; // Call the function you just wrote and store the// answer in the variable evens declared above. // This will print the number of evens in the array. cout << endl << evens; cout << "\nPart 4" << endl; // Part 4// Write a function called computeTotalOdds. It takes in an array and// an integer that has the number of values in the array. It will return// the total of all of the odd numbers in the array int total; // Call the function you just wrote and store the answer// in the variable total declared above// This will print the total outcout << endl << total; return 0;}

ansver
Answers: 1

Another question on Engineering

question
Engineering, 03.07.2019 14:10
The y form of iron is known as: a) ferrite b) cementite c) perlite d) austenite
Answers: 3
question
Engineering, 04.07.2019 16:10
An electrical motor raises a 50kg load at a construct velencity .calculate the power of the motor, if it takes 40sec to raise the load through a height of 24m(take g =9.8n/g)
Answers: 2
question
Engineering, 04.07.2019 18:10
Ariver flows from north to south at 8 km/h. a boat is to cross this river from west to east at a speed of 20 km/h (speed of the boat with respect to the earth/ground). at what angle (in degrees) must the boat be pointed upstream such that it will proceed directly across the river (hint: find the speed of the boat with respect to water/river)? a 288 b. 21.8 c. 326 d. 30.2
Answers: 3
question
Engineering, 04.07.2019 18:10
Burgers vector is generally parallel to the dislocation line. a)-true b)-false
Answers: 2
You know the right answer?
PLEASE CODE IN C++#include using namespace std;int main(){int array1[20] = {3, 18, 1, 25, 4, 7, 30,...
Questions
question
Mathematics, 19.12.2020 05:00
question
Mathematics, 19.12.2020 05:00
question
Arts, 19.12.2020 05:00
Questions on the website: 13722359