cout << "Enter the amount of times you wish the program to loop. Make sure your input is greater than or equal to 1: "
cin >> nLoopCount;
cout << "You have " << nLoopCount << " loops left. :D" << "\n";
} while (nLoopCount <= 1);
So, here I am not sure what I am doing wrong. I am a beginner and am trying to learn the ways to become a successful programmer.
What I am trying to do here is have the user cin a value (whatever it is since i know it will run through the statment once without checking the condition) and have it keep looping if the statement is true. This would check if the statement is true at the end and keep going if it continues to be true (looping).
The outcome is that if any number is greater than 1, it will run through the statement only once and subtract one from the cin (nLoopCount). For instance, if i input 6, I would get 5. If it equals one,zero, or is negative the statement will keep subtracting into the negatives, never stopping.
Any help would be much appreciated! Thank you (all) so much!