Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Test your random number generator. Draw a flowchart and write a C function that will test your random number generator. Compare it against rand() function
Test your random number generator. Draw a flowchart and write a C function that will test your random number generator. Compare it against rand() function from standard C library. For this, generate a lot of random numbers (>100k), keep each number's count, and print the normalized results at the end in tab separated order. You should have main.c, test_random.c, test_random.h, myrand.c and myrand.h files. Problem 1 (10 pts). Pseudo-random number generator. Draw a flowchart for a pseudo-random number generator, then write its C function. The generated random number should be between [1, 15]. It should be a pure C function without any external function calls. (i.e rand()) Explain your method. You should have main.c, myrand.c and myrand.h files. myrand.c should have your random number generator function definition. myrand.h should have a function declaration. main.c should include your myrand function and call it.
Ask an expert
Draw a flowchart for a pseudo-random number generator, then write its C function. The generated random number should be between [1, 15]. It should be a pure C function without any external function calls. (i.e rand()) Explain your method. You should have main.c, myrand.c and myrand.h files. myrand.c should have your random number generator function definition. myrand.h should have a function declaration. main.c should include your myrand function and call it.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started