I have 10 elements of Array, how can i remove 5 array
element, with single function.
Answer Posted / dhir
<?php
$a[0]='a';
$a[1]='b';
$a[2]='c';
$a[3]='d';
$a[4]='f';
$a[5]='g';
$a[6]='h';
$a[7]='i';
for($b=0;$b<=4;$b++)
{
$a=shift($a[$b]);
}
?>
Is This Answer Correct ? | 1 Yes | 3 No |
Post New Answer View All Answers
What is csrf token in php?
Tell me how is it possible to parse a configuration file?
Tell me can the value of a constant change during the script's execution?
When do sessions end?
Is php easier than node?
What is the sign to start variables in PHP?
Tell me what is the definition of a session?
What is rest api in php?
What is php and what does it do?
Which is better get or post method?
what is PDO?
How to move uploaded files to permanent directory?
What is difference between strstr() and stristr() in PHP?
Code to open file download dialog in PHP?
Write an example to remove html tags from a string in php?