r/AskProgramming • • Nov 02 '20

Does randomness really exist in computers, where everything has to be an output of a logical calculation at the core of a computer's hardware? Is it really a random result that a random number picker out of a set of numbers gives you?

Thank you

53 Upvotes

65 comments sorted by

View all comments

6

u/YMK1234 Nov 03 '20

So many wrong answers here. Any modern x86 CPU has a true source of randomness built in, which you can easily achieve by reading sensor noise for example. And even before that you could buy dedicated RNGs which for example came as a small package of a radiation source to generate random fission events, which can be detected.

You cannot compute randomness, but computers do more than computing, they very much interact with the real world through their hardware, which makes them capable of randomness.