|
|
1.1 ! root 1: /* @(#)rand.c 4.1 (Berkeley) 12/21/80 */ ! 2: static long randx = 1; ! 3: ! 4: srand(x) ! 5: unsigned x; ! 6: { ! 7: randx = x; ! 8: } ! 9: ! 10: rand() ! 11: { ! 12: return((randx = randx * 1103515245 + 12345) & 0x7fffffff); ! 13: }
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.