Created the number gen. in C++