int main()
{
vector<double> list;
bool more = true;
while (more)
{
double x;
int yes;
cout << "Do you have numbers? yes=1 or no=2" "\n";
cin >> yes;
if(yes == 1)
{
cout << "Enter number""\n";
cin >> x;
list.push_back(x);
yes = 0;
}
if (yes == 2)
more = false;
}
so far as i can tell this compiles fine, but once i have added the desired number of items for the vector and punch in "2" the program starts and does not go on to the next part after the while loop. I have commented out everything else outside of this loop but i cannot see the break.
Any help would be great