Tuesday, February 4, 2014

Php program using loops

<html>
<body>

<?php
$i=1;
do
  {
  $i++;
  echo "The number is " . $i . "<br />";
  }
while ($i<=5);
?>

</body>
</html>

OUTPUT:
The number is 1
The number is 2
The number is 3
The number is 4
The number is 5

No comments:

Post a Comment