Question: PHP CODE QUESTION Thank You Your task is to complete the PHP code below. It should sort the numbers both from greatest to lowest as

PHP CODE QUESTION

PHP CODE QUESTION Thank You Your task is to complete the PHPThank You

Your task is to complete the PHP code below. It should sort the numbers both from greatest to lowest as well as lowest to greatest, then print them as shown in the example output. The numbers are sent to the program as a string in which the numbers are separated by comma (for example "4,2,5,2"). The explode function is used to split them into an array. Using PHP's standard sort function isn't allowed. The sorting has to be done using for-statement. The in-complete code: Example output: Order in the beginning: 8,65,5,32,76,8,43,32,47,9,34,432,8,9,54,2,54,67,7,332,76,8 From greatest to lowest: 432,332,76,76,67,65,54,54,47,43,34,32,32,9,9,8,8,8,8,7,5,2 From lowest to greatest: 2,5,7,8,8,8,8,9,9,32,32,34,43,47,54,54, 65, 67,76,76,332,432

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!