Question: COURSE LANGUAGE : ADVANCE C PROGRAMMING Write a program to create two arrays with minimum five elements each. Merge the arrays to a new array
COURSE LANGUAGE : ADVANCE C PROGRAMMING
Write a program to create two arrays with minimum five elements each. Merge the
arrays to a new array in such a way that first array may be copied as it is and reverse
only the second array and mergeit. Perform sorting in the new array and print it.
Implement the same by passing appropriate arrays tofunctions. Below is the sample
output.
Sample I/P and O/P
Enter the number of elements for
First Array : 4Enter the elements for
First Array :
4
13
12
1
Enter the number of elements for
Second Array :
Enter the elements for Second Array :
4
6
7
8
9
Elements After Merging 4 13 12 1 9 8 7 6
The sorted elements are 1 4 6 7 8 9 1
2
2. Write a program to create two arrays with minimum five elements each. Merge the arrays to a new array in such a way that first array may be copied as it is and reverse only the second array and mergeit. Perform sorting in the new array and print it. Implement the same by passing appropriate arrays tofunctions. Below is the sample output. Sample I/P and O/P Enter the number of elements for First Array : 4Enter the elements for First Array : 4 13 12 1 Enter the number of elements for 4 Second Array: Enter the elements for Second Array: 6 7 8 9 ElementsAfterMergingThesortedelementsare4113412617988971613
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
