Created
March 29, 2012 12:23
-
-
Save garak/2236841 to your computer and use it in GitHub Desktop.
script per estrare un biglietto gratis per il phpDay/jsDay
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 | |
$p = array( | |
// gennaio | |
'arnaldo', | |
'giorgio', | |
'antonio', | |
'david', | |
'jacopo', | |
'luca', | |
'alessandro', | |
'vittorio', | |
'filippo', | |
'marco', | |
'francesco', | |
'andrea', | |
// febbraio | |
'david', | |
'leonardo', | |
'marco', | |
'alessandro', | |
'fabio cicerchia', | |
'antonio', | |
'jacopo', | |
'eugenio', | |
'francesco', | |
'moglie francesco', | |
'yari', | |
'arnaldo', | |
'fabio doddi', | |
// marzo | |
'alessandro', | |
'leonardo', | |
'marco', | |
'eugenio', | |
'arnaldo', | |
'antonio', | |
'francesco', | |
'moglie francesco', | |
'yari', | |
'fabio cicerchia', | |
); | |
$chiavi = array_rand($p, 3); | |
foreach ($chiavi as $k) { | |
echo PHP_EOL . $p[$k]; | |
} | |
echo PHP_EOL; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment