Last active
November 28, 2018 15:36
-
-
Save m3m0r7/2207d133c8de40a9b7be724d99a60596 to your computer and use it in GitHub Desktop.
This file contains hidden or 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 function z($_,$p){return array_filter($_,function($v)use($p){return$v%$p==0;});}function x(&$_,$p){array_walk($_,function(&$v)use($p){$v=$p;});}$y=@array_keys;$a=array_combine($a=$y(array_fill(1,100,0)),$a);$b=z($a,3);$c=z($a,5);$d=array_intersect($b,$c);x($b,@Fizz);x($c,@Buzz);x($d,@FizzBuzz);$f=$d+$c+$b+$a;ksort($f);echo join("\n",$f); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment