0b44a031
1 2 3 4 5 6 7 8 9 10 11 12 13
#include <stdlib.h> static unsigned seed; void srand(unsigned s) { seed = s-1; } int rand(void) { return (seed = (seed+1) * 1103515245 + 12345 - 1)+1 & 0x7fffffff; }