3v4l.org

run code in 300+ PHP versions simultaneously
<?php /* results of resArr */ $resArr = array( "06" => 1, "16a" => 2, "16b" => 1, "A &E" => 15, "AOU" => 5, "Burns Unit" => 2, "Hospital Other" => 3, "Maternity" => 2, "Missing" => 2, "Recovery" => 1, "St Andrews" => 1, "St Patricks" => 1, "Ward 1" => 2, "Ward 2" => 1, "Ward 4" => 21, "Ward 5" => 7, "Ward 6" => 3, "Ward 7" => 6, "Ward 8" => 1, "Ward 9" => 4, "Ward 10" => 12, "Ward 15" => 5, "Ward 16a" => 15, "Ward 16b" => 5, "Ward 17" => 7 ); echo 'Pre-Sorted'; echo print_r($resArr); echo '----------'; /* sort by the value, from greatest to smallest */ rsort($resArr); echo 'Sorted'; echo print_r($resArr);
Output for rfc.property-hooks, git.master, git.master_jit
Pre-SortedArray ( [06] => 1 [16a] => 2 [16b] => 1 [A &E] => 15 [AOU] => 5 [Burns Unit] => 2 [Hospital Other] => 3 [Maternity] => 2 [Missing] => 2 [Recovery] => 1 [St Andrews] => 1 [St Patricks] => 1 [Ward 1] => 2 [Ward 2] => 1 [Ward 4] => 21 [Ward 5] => 7 [Ward 6] => 3 [Ward 7] => 6 [Ward 8] => 1 [Ward 9] => 4 [Ward 10] => 12 [Ward 15] => 5 [Ward 16a] => 15 [Ward 16b] => 5 [Ward 17] => 7 ) 1----------SortedArray ( [0] => 21 [1] => 15 [2] => 15 [3] => 12 [4] => 7 [5] => 7 [6] => 6 [7] => 5 [8] => 5 [9] => 5 [10] => 4 [11] => 3 [12] => 3 [13] => 2 [14] => 2 [15] => 2 [16] => 2 [17] => 2 [18] => 1 [19] => 1 [20] => 1 [21] => 1 [22] => 1 [23] => 1 [24] => 1 ) 1

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
42.9 ms | 1662 KiB | 4 Q