September 2017
Beginner to intermediate
384 pages
9h 18m
English
Now that we've seen how to generate random bits on demand, let's look at how to convert those random bits to numeric values matching a particular distribution. This two-step process--generate raw bits, and then format them into data values--is very similar to the two-step process of buffering and parsing we covered in Chapter 9, Iostreams. First, get the raw bits and bytes, then perform some kind of operation to convert those bits and bytes into typed data values.
Given any distribution object dist, you can perform the following operations on it:
Read now
Unlock full access