Question: Please I need help!!!! DO NOT CHANGE THE CODE // Libraries to be included // Global variables int n; // Forward definition void readlist (int


Please I need help!!!!
DO NOT CHANGE THE CODE
// Libraries to be included // Global variables int n; // Forward definition void readlist (int [n] ); void printlist (int [n]); void sortlist (int[n]); // Main function int main () // Read the n value from the user printf("Please give the number of elements in the list "); // TODo read the number from the user // Create the list of numbers int list [n]; // Read the list of numbers readlist (list); // sort the list sortlist(list); // Print ordered list printlist(list); // Print the mean value in the list int meanposition =n/2; return ; \} // Function to read the list of numbers void readlist (int L[n]){ // ToDo write the code to read the list of numbers 3 // Function to print the list void printlist (int l[n]){ //TODo write the code to print the list of numbers \} // Function to sort the list void sortlist (int l[n]){ // TODO write the code to sort the list 1. For this program you will complete the program in the c file. Find the places in the code marked with the ToDo label and complete the work. You should not change any other part of the code. This includes do not add any global variable or any other function. This C program obtains the median value of a given list of integer numbers. The median is the value that is localized in the middle of the list once the list is sorted. The program asks for the number, n, of numbers in the list, then proceeds to read the list and sort it. The sorting process should be implemented using the bubble sort algorithm. The output should include the ordered list and the number that represents the mean value in the list. Please see the test cases below and make sure that your program reads the values and show the outputs as in the images. Make sure that your output exactly matches the test cases below. Please carefully observe the details when the number of numbers in the list is an even or an odd number. Test your program with the same test cases provided below, take a screenshot of the output for each test case. Create a file named "a03". Create a section in this document called Program01 and paste your screenshots under this section. Test case 1 - number of numbers in the list is odd Test case 2 - number of numbers in the list is even Please give the number of elements in the list 8 Please give number 0:4 Please give number 1: 9 Please give number 2: 8 Please give number 3: 7 Please give number 4: 1 Please give number 5: 5 Please give number 6: 9 Please give number 7: 2 1 2457899 The mean value of the list is: 7
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
