Question: c++ and explain Implement two integer arrays of capacity 9. a) Initialize the first array with values 10, 20, 30, 40, 50, 60, 70, 80,
c++ and explain



Implement two integer arrays of capacity 9. a) Initialize the first array with values 10, 20, 30, 40, 50, 60, 70, 80, and 90. b) Use a loop to copy all of the values of the first array in reverse to the second array. c) Use a loop to output two arrays. Example Output Original: 10 20 30 40 50 60 70 80 90 Reversed: 90 80 70 60 50 40 30 20 10 Implement one array of the English alphabet (26 characters). a) Create a function, getLetters() to cast and generate the array. b) Create a function, printLetters() to output the array. c) Create a function, swap() for swapping character variables. d) Create a function, reverse Letters() uses a loop and the swap() to reverse all array elements. e) Call printLetters() to Output the updated array. Hint: Set a variable for the first and last indices. Swap those values. Gradually move the first/last pointers to the middle of the array, swapping as you go. When the middle is reached, the array will be reversed. Example Output Original: ABCDEFGHIJKLMNOPQRSTU V W X Y Z Reversed: 2 Y XW VUT SRO PONMLKJIHGFED CBA
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
