Stuck on "Digit Extractor"

Ok, I asked this question last week, and got the code started, im just confused how to keep it going.

The program is supposed to ask you to enter a five digit number(12345) display it like this. http://img.photobucket.com/albums/v323/Monkeyman1010/homework.gif

So far my code is....

int main()
{
int fnum1;

cout <<"\nEnter 5 Digit Number:";
cout << endl;
cin >> fnum1;
fnum1 = (12345 % 10);
cout <<"\nOnes Digit is:" << fnum1;
cout <<"\nTens Digit is:";


return 0; // indicate that program ended successfully

}



I can get it to display the ones digit, but i am not sure how to get it to display the rest... any help?
Hint.

12345 % 10 = 5;
12345 / 10 = 1234

ok. I figured this out!
Topic archived. No new replies allowed.