Answers for "for i in php"

PHP
10

for loop php

<?php
	$fruits = ["apple", "banana", "orange"];
	for($i=0;$i<count($fruits);$i++){
    echo "Index of ".$i."= ".$fruits[$i]."<br>";
    }
  ?>
Posted by: Guest on December-28-2019
0

php for loop

for($i = 1; $i > 10; $i++){
  //show i value
	echo "Your Number Is :$i";
}
Posted by: Guest on September-03-2021

Browse Popular Code Answers by Language