+ 20
Can a program be able to generate truely random numbers?
5 Answers
+ 8
Jtrh ok by the mean of physical phenomena i can do that on microcontrollers and on some programable boards boards in small range but if you have to create that on sololearn then how you will do that?
+ 7
No but you should be able to get a random number generated by the noise from your hardware eg: /dev/random for Linux
+ 4
Anirudh Sharma hmm Thnx.
Good suggestion
+ 2
A software can't do that it contains a pattern it might be unimaginably long pattern but It can't be 100 percent random
- 1
Read this carefully, though this is not quiet an answer:
In maths, 1Ă·0 is Not Defined.
But if we go for a small number, we get interesting results...
1Ă·0.00000001 = 10^8
As a matter of fact we have a special topic in maths( called limits ) to deal with such results.
Lim xâ0 1/x = â
Now to your question:
If i use math.rand i get a predictable number*(say).
Lets call it Râș1
If i use math.rand to generate a random key and then use math.rand, i get a somewhat predictable number. Râș2
If i use
math.rand(math.rand(math.rand()*f)*f), i get a not-so-predictable number. Râș3
I, a mere weak human, doesnt posses such power as thanos to be able to predict Râș4 and beyond. Even Râș3 will require 21.1415 hours for me.
So use a computer and generate Râș100 (which should be enough)
Remember:
Lim xââ Râșx = not at all predictable number.