subject

Add each element in origList with the corresponding value in offsetAmount. Print each sum followed by a space. Ex: If origList = {40, 50, 60, 70} and offsetAmount = {5, 7, 3, 0}, print:45 57 63 70 #include using namespace std;int main() {const int NUM_VALS = 4;int origList[NUM_VALS];int offsetAmount[NUM_VALS];int i = 0;origList[0] = 40;origList[1] = 50;origList[2] = 60;origList[3] = 70;offsetAmount[0] = 5;offsetAmount[1] = 7;offsetAmount[2] = 3;offsetAmount[3] = 0;// your solution goes here

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 07:00
You will be given two character arrays of the same size, one will contain a number of ships. ships will move around the character array based on which way they are facing and the route they are on. routes are given in the other array. the route consists of '-' and '|' for straight paths, '\' and '/' for curves, and '+' for intersections. there are ships on these routes. ships always face a direction, '^' for up, '> ' for right, 'v' for down, and '< ' for left. any time the ships hit a '\' or a '/' it will turn as you would expect a ship to turn (e.g. a '^' that moves into a '/' will turn right). at an intersection, ships will always continue straight through. all ships move at the same speed, ships take turns moving and all ships move during one 'tick'. the one in the most top left goes first, followed by those to its right, then the ones in the next row. it iterates along the rows and then down the columns. each ship moves one space on its turn moving along the route. your function needs to return the position of the first collision between two ships and the number of ticks before the crash occurred.
Answers: 2
question
Computers and Technology, 22.06.2019 23:30
In my email i got a message it says a quick message and in message details on who its from its says nicole and under nicole is [email protected] -
Answers: 1
question
Computers and Technology, 23.06.2019 06:40
What are the three uses of a screw?
Answers: 2
question
Computers and Technology, 23.06.2019 19:50
Which feature is selected to practice and save the timing of a presentation
Answers: 1
You know the right answer?
Add each element in origList with the corresponding value in offsetAmount. Print each sum followed b...
Questions
question
Mathematics, 10.10.2019 05:40
question
Mathematics, 10.10.2019 05:40
question
Biology, 10.10.2019 05:50
question
Social Studies, 10.10.2019 05:50