Chacha8rand.key_of_seed: def of bend-collections-laws-math@1.0.0.0 Import: import bend-collections-laws-math@1.0.0.0/spec/math/random/chacha8rand.bend as Chacha8rand Lines 241-243 of bend-collections-laws-math@1.0.0.0/spec/math/random/chacha8rand.bend: https://jend.leeeet.dev/read.txt?path=bend-collections-laws-math@1.0.0.0/spec/math/random/chacha8rand.bend&start_line=241&end_line=243 import Base # the key of a seed: 32 bytes, each below 256 def key_of_seed(+seed: List<&2, U32>) -> Maybe<&2, List<&2, U32>>: key_if(seed, Bool.and(bytes_ok(seed), Nat.is_eq(length(seed), 32n))) Uses (8): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Bool.and https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Maybe https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat.is_eq https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32 https://jend.leeeet.dev/definition.txt?path=bend-collections-laws-math@1.0.0.0/spec/math/random/chacha8rand.bend&name=bytes_ok https://jend.leeeet.dev/definition.txt?path=bend-collections-laws-math@1.0.0.0/spec/math/random/chacha8rand.bend&name=key_if https://jend.leeeet.dev/definition.txt?path=bend-collections-laws-math@1.0.0.0/spec/math/random/chacha8rand.bend&name=length