Skip to content

Instantly share code, notes, and snippets.

@halka
Created February 6, 2020 06:46
Show Gist options
  • Save halka/f72195c9c91ebf25a05883dda476a755 to your computer and use it in GitHub Desktop.
Save halka/f72195c9c91ebf25a05883dda476a755 to your computer and use it in GitHub Desktop.
fizzbuzz
<?
for($i = 1; $i<=100; $i++){
if($i % 15 === 0 ) echo "FizzBuzz";
elseif($i % 3 === 0) echo "Fizz";
elseif($i % 5 === 0) echo "Buzz";
else echo $i;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment