0
C program code ( i need written code as i have no knowledge about c )
Write a ‘C’ program to read a list of ‘n’ integers from the keyboard and rearrange the elements in the list (i) in ascending order and (ii) in descending order and display the results. The value of ‘n’ must be read from the keyboard at run time by giving the following prompt message to the user - “ENTER THE VALUE OF n :”. Also read all the ‘n’ integers from the keyboard one after another at run time by giving the following prompt message - “NOW ENTER THE INTEGER NUMBERS:”. Can someone write this code?
5 Answers
+ 5
Show your attempt first
+ 2
ÃKR Couldnt know how to begin also☹️ it was given at linux lesson
+ 1
A.S. Can you write it for me, please?
+ 1
First use scanf to take input as integer
Use scanf to take input inside for loop and save each value in array
Use any sorting algorithm to sort it in ascending order and print it.
After that start printing each value inside array in reverse order.
sololearn != "Do My Homework";
0
question seem easy you need basic input output statements and for sorting you can use any algorithm like insertion sort , merge sort......