1Random.State(3) OCaml library Random.State(3)
2
3
4
6 Random.State - no description
7
9 Module Random.State
10
12 Module State
13 : sig end
14
15
16
17
18
19
20
21 type t
22
23
24 The type of PRNG states.
25
26
27
28 val make : int array -> t
29
30 Create a new state and initialize it with the given seed.
31
32
33
34 val make_self_init : unit -> t
35
36 Create a new state and initialize it with a system-dependent low-en‐
37 tropy seed.
38
39
40
41 val copy : t -> t
42
43 Return a copy of the given state.
44
45
46
47 val bits : t -> int
48
49
50
51
52 val int : t -> int -> int
53
54
55
56
57 val full_int : t -> int -> int
58
59
60
61
62 val int32 : t -> Int32.t -> Int32.t
63
64
65
66
67 val nativeint : t -> Nativeint.t -> Nativeint.t
68
69
70
71
72 val int64 : t -> Int64.t -> Int64.t
73
74
75
76
77 val float : t -> float -> float
78
79
80
81
82 val bool : t -> bool
83
84
85
86
87 val bits32 : t -> Int32.t
88
89
90
91
92 val bits64 : t -> Int64.t
93
94
95
96
97 val nativebits : t -> Nativeint.t
98
99 These functions are the same as the basic functions, except that they
100 use (and update) the given PRNG state instead of the default one.
101
102
103
104
105
106OCamldoc 2022-07-22 Random.State(3)