Last active
June 10, 2019 13:09
-
-
Save flaviors200/60ef8ffc32f9c38fa6ee945ea994fda3 to your computer and use it in GitHub Desktop.
Loop statements: for
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$colors = ['blu', 'giallo', 'verde', 'rosso', 'bianco']; | |
for ($i = 0; $i < count($colors); $i++) { | |
echo "$colors[$i]\n"; | |
} | |
/** Output ** | |
/ blu | |
/ giallo | |
/ verde | |
/ rosso | |
/ bianco | |
/*/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment