Is there any actual difference between the following for and while functions?
Say we have the following, for example's sake. Is there any performance
difference, usage difference between the following, or is it just a
personal preference?
for($i=0; $i<10; $i++){
echo $i;
}
and
$i = 0;
while($i < 10){
echo $i;
$i++;
}
No comments:
Post a Comment