I want to cout
an integer starting 0. For example, 0123456789.
But when I print it out, it only display 123456789
instead of 0123456789
.
How can I solve this problem?
Below is my sample code:
sample.txt
0125961349
01359395930
019349130
I parse 1 of the contact number into an object, eg: 019349130. hence:
cout << cp.contactNum << endl;
and the final result is
19349130
This is not the result I want. And you can see I have different length for the integer, I cannot use the leading zero solution to solve it or else it will become something like 0019349130
.