#include <iostream>
using namespace std;
#include <random>
#include <memory>
class BaseRandom
{
public:
virtual int next_int() = 0;
};
template <class T>
class ConcreteRandom : public BaseRandom
{
public:
virtual int next_int() {
return prng();
}
T prng;
};
int main() {
auto random = std::make_unique<ConcreteRandom<std::mt19937>>();
random->next_int();
return 0;
}
I2luY2x1ZGUgPGlvc3RyZWFtPgp1c2luZyBuYW1lc3BhY2Ugc3RkOwoKI2luY2x1ZGUgPHJhbmRvbT4KI2luY2x1ZGUgPG1lbW9yeT4KCmNsYXNzIEJhc2VSYW5kb20KewpwdWJsaWM6Cgl2aXJ0dWFsIGludCBuZXh0X2ludCgpID0gMDsKfTsKCnRlbXBsYXRlIDxjbGFzcyBUPgpjbGFzcyBDb25jcmV0ZVJhbmRvbSA6IHB1YmxpYyBCYXNlUmFuZG9tCnsKcHVibGljOgoJdmlydHVhbCBpbnQgbmV4dF9pbnQoKSB7CgkJcmV0dXJuIHBybmcoKTsKCX0KCQoJVCBwcm5nOwp9OwoKaW50IG1haW4oKSB7CglhdXRvIHJhbmRvbSA9IHN0ZDo6bWFrZV91bmlxdWU8Q29uY3JldGVSYW5kb208c3RkOjptdDE5OTM3Pj4oKTsKCXJhbmRvbS0+bmV4dF9pbnQoKTsKCXJldHVybiAwOwp9