Computer Science, asked by darkmatterT01, 2 months ago

Write a menu driven program in C language to do the following operations.
1. Even/ODD element Array Count and Replace
2. Transpose of a matrix
Note:
For option 1, read the integer array, Count the total odd elements, count the total even elements and replace all odd numbers of the array by multiplying -1 with the individual odd numbers and replace all even numbers by 100. Finally display the Total no of odd elements in the array, Total no of even elements in the array and the final array, after replacing.


Sample output
Menu :
1. Even/ODD element Array Count and Replace
2. Transpose of an matrix
Enter the choice :1
Enter the total elements of the array: 5
Enter the elements of the array: 1 2 3 4 5
Total no of odd elements in the array is 3
Total no of even elements in the array is 2
The resultant array after replace
-1 100 -3 100 -5
Do you want to continue, yes-y, no-n:y
1. Even/ODD element Array Count and Replace
2. Transpose of a matrix
Enter the choice :2
Enter The array element of the Matrix
1 2 3 4 5 6 7 8 9
The transpose of the Matrix
1 4 7
2 5 8
3 6 9

Do you want to continue, yes-y, no-n:n
Thank you

Answers

Answered by soundharrajan151
0

Answer:

yes I want to continue ok

Similar questions