I\'m trying to ask the user to enter numbers that are put into a vector,
then using a function call to count the numbers, why is this not
working? I am only able to count t
#include
#include
#include
using namespace std;
int main()
{
vectorV;
int num;
cin>>num;
string input;
while (cin>>input && num != 0) //enter any non-integer to end the loop!
{
//cin>>input;
V.push_back(input);
num--;
if(num==0)
{
vector::iterator it;
for(it=V.begin();it!=V.end();it++)
cout<<*it<