求救————使用标准库函数qsort(),对浮点数组进行从小到大排序!
使用标准库函数qsort(),对浮点数组进行从小到大排序!
数组如下:
{32.1, 456.78, 332.67, 442.0, 98.12, 451.79, 340.12, 54.55, 99.87, 72.5}
小弟我现在的疑点是不知道qsort(void*,size_t nelem,size_t width,int(*fcmp)(const void*,const void*))内部的运行机理,不知道怎么调用那个比较函数fcmp!
还望大侠们指点!