#include template static double randomGenrate(double begin, double end) { static auto randomGenrator = QRandomGenerator64::global(); auto rand = randomGenrator->bounded(static_cast(begin * P), static_cast(end * P)); return static_cast(rand) / P; }