// seed srand
srand ( time(NULL) );
// add some strings to a vector
std::vector<std::string> svec;
svec.push_back("Cake");
svec.push_back("Fish");
svec.push_back("Cookie");
// find the size of the vector
size_t max_size = svec.size();
// generate the random number between 0 and the size of the vector
constint random = (rand() % max_size) + 0;
std::cout << svec[random] << std::endl;