Hi, I'm new in this forum and also new at programming
I'm taking a C course at college but our lecturer is quite lazy, so we need to investigate most of the stuff. Currently, I'm stuck working with an array exercise, after headdesking for a while I managed to declare and initialize one, but I've problems sorting its elements.
Exercise: creating an array of five elements as doubles, asking the user to enter values and print the sorted array.
This is what I wrote so far:
I can ask for 5 numbers stored as doubles (as asked in the problem) but I don't know how to sort the numbers. I've tried everything but without success, so I'm asking for help here
/* User interaction module */
puts("Please enter five values:");
/* Printing the array */
printf("%lf, %lf, %lf, %lf, %lf \n", value, value, value, value,value);