Ledger Nano X - The secure hardware wallet
SHARE
TWEET

Untitled

a guest Nov 30th, 2012 241 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. <?php
  2. $numbers = array(12, 26, 29, 30, 36, 38);
  3.  
  4. //Генерираме 6 произволни числа в диапазона от 1 до 49
  5. $othernumbers = range(1, 49);
  6. shuffle($othernumbers);
  7. $othernumbers = array_slice($othernumbers, 0, 6);
  8.  
  9. foreach($numbers as $key=>$value) {
  10.  
  11. $match = ($value == $othernumbers[$key])?'<font color="green">Да!</font>':'<font color="red">Не!</font>';
  12.  
  13.  
  14.  // Извеждаме информацията!
  15. echo "
  16. Число от тиража: <b>$value</b>
  17. <br />
  18. Генерирано число: <b>$othernumbers[$key]</b>
  19. <br />
  20. Съвпадение: <b>$match</b>
  21. <hr />";
  22.  
  23. }
  24.  
  25. ?>
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Top