# Hello world, vectors, review. It keeps skipping std::cin. Pls help

Hi it’s me again.
I have a logic error where it keeps skipping std::cin.
I don’t know what’s wrong please help me.

Here’s the code:

``````include<iostream>

#include<vector>

int main() {

std::vector<int>Numbers;

int storage = 0;

int storage2 = storage;

std::cout <<"Welcome to the even and odd numbers calculator\n";

std::cout <<"Please enter first number (single digit only)\n";

std::cin >> storage;

Numbers.push_back(storage2);

std::cout <<"Next number please\n";

std::cin >> storage;

Numbers.push_back(storage2);

std::cout <<"And anoter one\n";

std::cin >> storage;

Numbers.push_back(storage2);

std::cout <<"Anoter one\n";

std::cin >> storage;

Numbers.push_back(storage2);

std::cout <<"And anoter one\n";

std::cin >> storage;

Numbers.push_back(storage2);

std::cout <<"Thank you, Here is your anser.\n";

double even = 0;

double odd = 0;

for (int i = 0; i < Numbers.size(); i++)  {

if (Numbers[i] == 1) {

odd = odd + Numbers[i];

}

else if (Numbers[i] == 2) {

even = even + Numbers[i];

}

else if (Numbers[i] == 3) {

odd = odd + Numbers[i];

}

else if (Numbers[i] == 4) {

even = even + Numbers[i];

}

else if (Numbers[i] == 5) {

odd = odd + Numbers[i];

}

else if (Numbers[i] == 6) {

even = even + Numbers[i];

}

else if (Numbers[i] == 7) {

odd = odd + Numbers[i];

}

else if (Numbers[i] == 8) {

even = even + Numbers[i];

}

else if (Numbers[i] == 9) {

odd = odd + Numbers[i];

}

}

std::cout <<"Sum of Even numbers\n";

std::cout << even<<"\n";

std::cout <<"Sum of Odd numbers\n";

std::cout << odd<<"\n";

std::cout <<"Thankyou for using the Even and Odd Numbers Calculator\n";

}
``````

Here’s a screenshot:

Thanks again for your help and support.
Sorry I Keep asking for help.

It’s possible that this lesson is not set up for user input so `std::cin` may not work.

Yes that is possible, but I tried it in workspace and it still didn’t work.

How do you set up though?

I will try to run it the way the instructions told me to, but please get back to me if you find a solution to my problem.