Have you ever needed to generate a random number in code? whether it's for rolling a dice, or shuffling a set, this tweet thread is here for you! There's no reason that it should be easy or obvious, very experienced programmers repeat common mistakes. I did, before I learned ...
It's got all of those anti-patterns like DoubleStreams and setSeed(), *shudder*. I gave up auditing its use because mistakes are so common and just tell people to use our replacement instead which can't be abused as easily.
-
-
We also over-ride the SPI so that setSeed() is a no-op!
Thanks. Twitter will use this to make your timeline better. UndoUndo
-
-
-
Oh, I see. Kotlin has already left those out I think :) Could you recommend a book or an article where the major anti-patterns are listed? Also I'll be sure to check out AmazonSecureRandom ASAP
Thanks. Twitter will use this to make your timeline better. UndoUndo
-
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.
I didn't know things were this bad. AFAIK the plan was to reuse JDK implementation on JVM. Should we not?