Registry / crypto / random

random

JSON →
library0.14.1rscratesunverified

The package provides sources of randomness.

# Cargo.toml [dependencies] random = "0.14.1"
INSTALL
IMPORT
SIG · RANDOM
R
random
cryptorustv0.14.1
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

Source
use random::Source;

Generate a random u32 value.

use random::Source; fn main() { let mut rng = random::default(); let val: u32 = rng.read(); println!("Random value: {}", val); }
Debug
Known issues

No known issues recorded.

Upgrade
Version history
0.14.1latest on crates.io
Audit
Dependencies

No dependency data recorded yet.

Agent activity
18 hits · last 30 days
node
16
Amazon
1
Resources
random — cargo add random · libregistry