fork download
  1. #include <stdio.h>
  2.  
  3. static unsigned int x = 123456789;
  4. static unsigned int y = 362436069;
  5. static unsigned int z = 521288629;
  6. static unsigned int w = 88675123;
  7.  
  8. unsigned int randint(void) {
  9. unsigned int t;
  10. t = (x ^ (x << 11));
  11. x = y; y = z; z = w;
  12. w = (w ^ (w >> 19)) ^ (t ^ (t >> 8));
  13. return w;
  14. }
  15.  
  16. int main(void) {
  17. int i;
  18. for (i = 0; i < 38; i++) {
  19. printf("%10u\n", randint() % 0x56000000);
  20. }
  21. return 0;
  22. }
  23.  
Success #stdin #stdout 0.01s 5280KB
stdin
Standard input is empty
stdout
 816006634
 458299110
1058032042
 747438256
 516391518
 934428998
1157108803
 717229868
 137866584
 395339113
1301295572
 285470245
 652989168
1187274473
 873912692
1176272085
 686574644
 448488982
 643481932
 934407046
 723553448
1047188492
 449460396
1285492136
 938840223
 830734233
 617066077
 544153312
  20906778
 795757459
 312261989
 811349640
 495109194
1055734842
 420990039
 472797579
 391216208
1050713708