PHP Programing language

R4R® PHP
(追記) (追記ここまで)
(追記) (追記ここまで)
array_shift() Function in PHP
(追記) (追記ここまで)
(追記) (追記ここまで)

array_shift()

The array_shift() function removes the first element from an array, and returns the value of the removed element.

Syntax:
array_shift(array)

In above syntax, "array" specifies an array

Example:

<?php
$a=array("a"=>"Apple","b"=>"Banana","c"=>"Orange");
echo array_shift($a)."<br>";
print_r ($a);
?>

Output:

Apple
Array ( [b] => Banana [c] => Orange )

(追記) (追記ここまで)
Copyright ©2021-22 r4r.co.in, all rights reserved. Theguestspost.com
Sitemap
Career
Post comment
About us
Subscription
Unsubscription

AltStyle によって変換されたページ (->オリジナル) /