I really like your approach for its pragmatism of just separating the thousands groups yourself, leaving conversion of the individual digits inside each group to the C++ standard library. However, your implementation isn't really perfect yet, which you can easily see when you're entering a simple number such as ten millions.