#include "RandomUtils.h"

#include <random>
#include <algorithm>
#include <iterator>

std::vector<unsigned> RandomUtils::getRandomVecUnsigned(std::size_t size)
{
    std::random_device rnd_device;

    std::mt19937 mersenne_engine {rnd_device()};
    std::uniform_int_distribution<unsigned> dist {0, 9};

    auto generator = [&dist, &mersenne_engine]()
    		{
    	return dist(mersenne_engine);
    		};

    std::vector<unsigned> vec(size);
    std::generate(std::begin(vec), std::end(vec), generator);
    return vec;
}
