Advertisement
hamjoricantiq

nested looping

Oct 1st, 2019
144
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
HTML 0.14 KB | None | 0 0
  1. <?php
  2.     $jumlah = 5;
  3.     for ($i = 1; $i <= $jumlah; $i++)
  4.     {
  5.         for ($j = 1; $j <= $i; $j++)
  6.         {
  7.             echo 'X ';
  8.         }
  9.         echo '<br/>';
  10.     }
  11. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement