Example -
We have 4 looping statements in PHP.
- for
- for each
- while
- do…..while
Code and Syntax –
<?php
$x=array("one","two","three");
foreach ($x as $value)
{
echo $value . "<br>";
}
?>
$x=array("one","two","three");
foreach ($x as $value)
{
echo $value . "<br>";
}
?>
Explanation
–
For more
php questions and answers, dumps,tutorials for beginners and experienced people
visit http://www.top-php-interview-questions.blogspot.in If you find any errors while executing this
program, you can make your comments or mail me at reply2sagar@gmail.com
No comments:
Post a Comment