Question
Write a program that inputs ten double-precision numbers into an array named raw. After ten user-input numbers are entered into the array, your program should
Write a program that inputs ten double-precision numbers into an array named raw. After ten user-input numbers are entered into the array, your program should cycle through raw ten times. During each pass through the array, your program should select the lowest value in raw and place the selected value in the next available slot in an array named sorted. Thus, when your program is complete, the sorted array should contain the numbers in raw in sorted order from lowest to highest. (Hint: Be sure to reset the lowest value selected during each pass to a number which is greater than the maximum value in array raw so that it is not selected again. You will need a second for loop within the first for loop to locate the minimum value for each pass.)
Code needs to be done in C
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started