Skip to content

Instantly share code, notes, and snippets.

@garak
Created March 29, 2012 12:23
Show Gist options
  • Save garak/2236841 to your computer and use it in GitHub Desktop.
Save garak/2236841 to your computer and use it in GitHub Desktop.
script per estrare un biglietto gratis per il phpDay/jsDay
<?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