1234
void HiddenNumberGenerator() { vector <char> HiddenNumber; int HiddenNumber = rand() % 9000+ 1000; }
int
123456
void HiddenNumberGenerator() { int temp; vector <int> HiddenNumber; temp = rand() % 9000+ 1000; HiddenNumber.push_back (temp); } //HiddenNumber goes out of scope here.