Why does the data not respond with the arsort sort?
The contents of the array are as follows, an array named $finaldata.
Array ([quest for accuracy] = 1 [adaptable] + 2 [expert analysis] + 2 [broad vision] + 2 [cool self-confidence] + 2 [considerate] = 2 [spur encouragement] and 2 [Smart] =& Gt 2 [to the best] + 2 [dedication] = 2 [Deep Ming and Primary] + 2 [Kwong na opinion] + 2 [loyal to cooperation] + 2 [creative] + 2 [treat people thoughtful] + 2 [discipline] and 2 [Highly efficient] + 2 [good encouragement] = 1 [bold] + 1 [Finish] = 1 [push forward] = 1 [imaginative] + 1 [unbiased] = 3 [disruptive innovation] + 1 [ UBM Good question] + 1 [Insight] + 0 [logic Clear] + 0 [loyal and reliable] + 0 [observation] + 0 [opportunity] + 0 [ingenuity] = 0 [hearty outward] + 0 [Candid Frank] + 0 [attention to detail] + 0 [perseverance] + 0 [convincing] + 1 [practical work] + 1 [dedicated] + 1 [realistic] + 1 [Trust yourself] + 1 [mind-wise ] = 1 [absorbed] = 1 [Skill] = 1 [unyielding] = 1 [methodical] = 1 [bossy] + 1 [fastidious] and 1 [quite impatient] + 1 [Dominion Knot Party] + 1 [capricious] = 1 [Retreat tolerance] + 1 [Careless forgetting] + 1 [timid] + 1 [fuss] + 1 [lack of patience] = 1 [Impulse recklessness] and 1 [indecision] =& Gt 1 [Inflexible] = 1 [Rigid conservative] + 1 [not aggressive] + 0 [play politics] + 0 [people indifferent] + 1 [too sensitive] + 1 [tongue-in-mouth] + 1 [Poor delegation] + 1 [Hold the remnant guard] = 1 [Suspicion suspicious] = 1 [slow action] = 1 [Hill doctrine] + 1 [deviant] + 0 [Dare not try] + 0 [impractical] + 0)
Apply the sort function of PHP
$finalData = Arsort ($finalData);p rint_r ($finalData);
But in the end there was no result.
Has anyone ever met such a problem? Or is there something wrong with my array?
------Solution--------------------
Arsort ($finalData);
Print_r ($finalData);
Arsort return value: Whether the sort succeeds, not the sorted array