Hi,
I'm new to C. All I was wondering is if there was a simple way to format output with the printf() function to have a long number (floats or ints) use commas...
1000000.00 is instead printed 1,000,000.00
I'm thinking it may involve using strings or an array of the number and print a "," for every third index. What is the easiest way? Are there alternative ways?
Thanks for your help in advance.
-Tyler
I'm new to C. All I was wondering is if there was a simple way to format output with the printf() function to have a long number (floats or ints) use commas...
1000000.00 is instead printed 1,000,000.00
I'm thinking it may involve using strings or an array of the number and print a "," for every third index. What is the easiest way? Are there alternative ways?
Thanks for your help in advance.
-Tyler