Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <string>
- using namespace std;
- int main () {
- // Variables
- int numInput;
- int numOfIntegers;
- bool canContinue;
- cout << "Enter the amount of integers you would like to enter: ";
- cin >> numOfIntegers;
- int oldNums = new int [numOfIntegers];
- while (canContinue) {
- cout << "Enter a random integer: ";
- cin >> numInput;
- if (numInput != -1) {
- } else {
- canContinue = false;
- }
- }
- }
Add Comment
Please, Sign In to add comment