NextIndexPrevious

Programs in PHP

6. Program to sort elements in an array in descending order.
<?php

	$arr = array(10,5,8,3,45);
	rsort($arr);
	print_r($arr);

?>
Output :

Array ( [0] => 45 [1] => 10 [2] => 8 [3] => 5 [4] => 3 )

Father of PHP

Rasmus Lerdorf

Rasmus Lerdorf

Born: November 22, 1968, Greenland