Skip to content

Instantly share code, notes, and snippets.



Last active Jun 10, 2019
What would you like to do?
Loop statements: for
$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
You can’t perform that action at this time.