I have an array that will have 5 numbers in it, what I need to do is sort this and have it return the array so I can manipulate the sorted array.
natsort() and sort only return true or false, which does not help me. So I need an alternative that will do what I need.
Example: The array may contain the following numbers in this order: 3 2 6 5 4
After it is sorted I want it to be like this: 2 3 4 5 6
I don't care if the original array is changed or if a new duplcate array is created. I just need a sorted array.
Any help is appreciate.
😕😕😕