Why do we not need to declare a var before using it in loops?


#1

<?php
// Write your for loop below!

  for($i=10;$i<101;$i=$i+10){
         echo $i.' ,'; 
          };
  ?>

like in this example .....why didn't we declare i as a variable first


#2

@the_vishal123,
You did declare the i variable with

$i=10

Have you tried
http://php.net/manual/en/langref.php