Question: The rand_r function in Figure 12.40 is implicitly reentrant. Explain. Figure 12.40 1 2 3 4 5 6 /* rand_r - return a pseudorandom integer
The rand_r function in Figure 12.40 is implicitly reentrant. Explain.
Figure 12.40

1 2 3 4 5 6 /* rand_r - return a pseudorandom integer on 0..32767 */ int rand_r(unsigned int *nextp) { } *nextp *nextp 1103515245+ 12345; return (unsigned int) (*nextp / 65536) % 32768;
Step by Step Solution
3.35 Rating (170 Votes )
There are 3 Steps involved in it
The randr function is implicitly reentrant function ... View full answer
Get step-by-step solutions from verified subject matter experts
