Once, my teacher taught me to use randomize() and random() function for generating pseudorandom numbers in C++ Builder. Now I prefer working in VS
It looks like you were using C-style functions, even though your question is labeled C++. Also, stdlib.h is a header file from C standard library. There's no such functions are random() and randomize() in C standard library. The C standard library has rand() and srand().
If you were using random() or something like that through stdlib.h, it must have been some non-standard library extension in Borland compiler package.
So, if you want to stick to C-style standard functions, that would be, again, rand() and srand(). But if you are writing in C++, you might have better (and more appropriate) options in C++ standard library.