The srand() function is used to generate truly random number. Can anyone explain this just confuse a lot why this need in rand | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 1

The srand() function is used to generate truly random number. Can anyone explain this just confuse a lot why this need in rand

11th Aug 2017, 1:50 AM
Naresh
Naresh - avatar
2 Answers
+ 6
This code may help you understand why seeding is important in RNG algorithms. https://code.sololearn.com/cMUCJqFL1X65/?ref=app
11th Aug 2017, 2:29 AM
Hatsy Rei
Hatsy Rei - avatar