I checked out your program, and it works great. I would change the wording of cout <<"Please enter 3-digit positive integer : "; to something more like cout<<"Please enter a 2 digit or larger, positive integer : ";
since your program will except numbers larger than 999.