| Crates.io | RaceNG |
| lib.rs | RaceNG |
| version | 1.0.3 |
| created_at | 2023-04-08 04:37:11.926601+00 |
| updated_at | 2023-04-08 05:44:06.975612+00 |
| description | Revolutionary, innovative, groundbreaking random number generator using race conditions |
| homepage | |
| repository | https://github.com/DvorakDwarf/RaceNG/tree/master |
| max_upload_size | |
| id | 833436 |
| size | 5,368 |
Revolutionary, innovative, groundbreaking random number generator using race conditions written in Rust. I wrote this in like an hour because I thought it would be funny (it was). I should not need to tell you this is not a reliable source of RNG you should rely on. If you do end up using it for smthn, please DM me on discord, I want to know.
cargo add RaceNG (Yes I uploaded it as a crate)let result = RaceNG::race(x, y)Sample output:

A race condition occurs when 2 or more threads are trying to use the same variable.
Both threads try to set the variable to a certain value, but due to computer jank, they go about it at different speeds. This means that the value of the shared variable is undefined at a given time. If you print the variable it is basically random.