Ipquarx

Untitled

Apr 16th, 2017
125
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.52 KB | None | 0 0
  1. function collectRandom(%rounds)
  2. {
  3.     $Random::numRounds = %rounds;
  4.     $Random::Iters = 100;
  5.    
  6.     $Random::randomString = "";
  7.    
  8.     doRound();
  9. }
  10.  
  11. function doRound()
  12. {
  13.     if($Random::numRounds <= 0)
  14.     {
  15.         printRandom();
  16.         return;
  17.     }
  18.    
  19.     %x = "";
  20.     %t = getRealTime();
  21.    
  22.     for(%a = 0; %a < $Random::Iters; %a++)
  23.         %x = %x @ "x";
  24.    
  25.     %t=getRealTime()-%t;
  26.    
  27.     $Random::randomString = $Random::randomString @ %t;
  28.     $Random::numRounds--;
  29.    
  30.     schedule(16, 0, doRound);
  31. }
  32.  
  33. function printRandom()
  34. {
  35.     echo($Random::randomString);
  36. }
Advertisement
Add Comment
Please, Sign In to add comment