函数的作用是用“自然排序”算法对数组排序。
In a natural algorithm, the number 2 is less than the number 10.
函数的作用是用“自然排序”算法对数组排序。数组内所有值的键保持不变。
The natsort() function sorts an array by using a "natural order" algorithm. The values keep their original keys.
比如,compare方法比较两个字符串;sort和asort方法以与相应的php数组函数相同的方式对数组或关联数组进行排序。
For example, the compare method compares two strings; the sort and asort methods sort arrays or associative arrays in a way similar to the corresponding PHP array functions.
用于对数组进行排序的函数是compareFunction,该函数是作为参数传递给 sort 函数的。
The function used to sort the array is the compareFunction that was passed into the function when it was called.
当你对数组使用选择排序,你选择最小的元素,其余的阵列每一个周期的循环。
When you sort an array using selection sort, you choose the smallest element in the rest of the array on each cycle of the loop.
函数的作用是:对数组按照键名逆向排序,元素的键名保持不变。
The krsort() function sorts an array by the keys in reverse order. The values keep their original keys.
函数的作用是:对数组按照键名逆向排序,元素的键名保持不变。
The krsort() function sorts an array by the keys in reverse order. The values keep their original keys.
应用推荐