Implement -d option.
This commit is contained in:
parent
286556f885
commit
d388877c1b
3 changed files with 9 additions and 1 deletions
3
misc.c
3
misc.c
|
@ -770,6 +770,9 @@ unsigned long get_next_lcg_value(void)
|
|||
/* Return the LCG's current value, and then iterate it. */
|
||||
unsigned long old_x = lcgstate.x;
|
||||
lcgstate.x = (lcgstate.a * lcgstate.x + lcgstate.c) % lcgstate.m;
|
||||
if (debug) {
|
||||
printf("# random %lu\n", old_x);
|
||||
}
|
||||
return(old_x);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue