4 ms·
Javascript random is only pseudoalleatory. I think you need a true random number generator to truly test this.
by Fargren 16y ago
Javascript random is only pseudoalleatory. I think you need a true random number generator to truly test this.
- cmos 16y agocan't it just get one from the server?
- lwat 16y agoRandom.org can help
- endtime 16y agoWhy would psuedorandomness be insufficient? Don't try to hack the JS and the effect should be the same.
- Fargren 16y agoIf it's pseudorandom, that means there's some form of pattern in the numbers it generates. It's impossible (or at least unreasonably hard) to know whether the person doing the test may subconciously guess or estimate the pattern. That invalidates the whole test.
- endtime 16y agoI suppose that's true, though if someone can intuit a crypto-strong PRNG then that's an interesting and significant result in itself.
- Fargren 16y agoSure, but when it's only being used to pick from between to picture sets, maybe it's not as impossible as it would seem.
- JeremyBanks 16y agoIt seems pretty impossible. Unless you're using a horribly flawed PRNG, patterns in the data should require analysis much deeper than human intuition could manage. This analysis would also probably require much more information than you would get from this experiment.
- nl 16y agoJavascript random() isn't a crypto-strong PRNG. Depending on how any PRNG is seeded, guessing it's output may not be very hard at all - especially if you've seen it once before. Eg, I once had a Poker playing game on an Amstrad that used a PRNG with a very predicable seeding strategy. I could amaze my friends by knowing exactly what cards I would be dealt.
- endtime 16y agoI'm not suggesting that JS's random() is crypto-strong. I was replying to this part: >I think you need a true random number generator to truly test this
- lwhi 16y agoUse a lava lamp and a webcam. EDIT: or http://www.lavarnd.org/ http://www.lavarnd.org/
- deleted 16y ago[deleted]