I 'm not quite sure if i did the right way but i just couldn't get the right value for my codes....can anyone figure out the problem?
for(int x = 0; x<myvector.size();x++)
{
if(number.compare(0,2,myvector[x],0,2)==0) //compare number(user's input) to the line read from getline
{
checknumber = true;
cout<<"passing compare++"<<endl;//if same number is found, then
break;
}
else
no++;
cout<<myvector[x]<<"value of myvector"<<endl;
}