C++11 RNG example from cppreference.com.