#include <tts/tools/random.hpp>
Generates a random value between two bounds.
This function generates a random value of type T between the specified mini and maxi bounds using an uniform distribution for integral types and a log-uniform distribution for floating-point types.
#define TTS_MAIN
#include <tts/tts.hpp>
{
for(auto i = 0; i < 100000; ++i)
{
}
};
- Parameters
-
| mini | Lower bound for the random value generation. |
| maxi | Upper bound for the random value generation. |
- Returns
- A random value of type T between mini and maxi.
- See also
- tts::randoms