i'm pretty new to php and i was working with arrays, while i came into this strange result
below is my code
while i run this code i get this result<html>
<head>
<title> Arrays Functions</title>
</head>
<body>
<?php $array1 = array(16,23,56,78,43,67,27); ?>
Count: <?php echo count($array1); ?><br />
Max: <?php echo max($array1); ?><br />
Min: <?php echo min($array1); ?><br />
Sort: <?php echo sort($array1); print_r($array1); ?><br />
Reverse Sort: <?php echo rsort($array1); print_r($array1); ?>
Implode: <?php echo $string1=implode(" * ", $array1); ?><br />
Explode: <?php echo print_r(explode(" * ", $string1))?>
In Array: <?php echo in_array(77,$array1); ?>
</body>
</html>
my issues is before Every Array there is a numeric one which is being displayed i have highlighted in red color, could some one kindly letme know why it is appearing???Count: 7
Max: 78
Min: 16
Sort: 1Array ( [0] => 16 [1] => 23 [2] => 27 [3] => 43 [4] => 56 [5] => 67 [6] => 78 )
Reverse Sort: 1Array ( [0] => 78 [1] => 67 [2] => 56 [3] => 43 [4] => 27 [5] => 23 [6] => 16 ) Implode: 78 * 67 * 56 * 43 * 27 * 23 * 16
Explode: Array ( [0] => 78 [1] => 67 [2] => 56 [3] => 43 [4] => 27 [5] => 23 [6] => 16 ) 1 In Array:
Sorry if this question is stupid
Thank you all in advance
Harish