Hi to all
I have a quick question. How can go through the integer to find if there is any specific number. For example my input would be 234446 (integer is of type long),and now I would like to check that integer and find how many 4's are in there and then display it.
Thank for reply
but it don't work, try yourself, I'm sending you piece of code. No matter what numbers you pick, it is just not right (or maybe its me)
using namespace std;
cout<<"Enter an integer: ";
cout<<"We have: "<<found5<<" 5's and we have: "<<found8<<" 8's";