Advertisement

integer to char ?

Started by April 21, 2002 10:42 AM
11 comments, last by Madness 22 years, 6 months ago
He means base 10, not 10 digits.
I think you missed Beer Hunter''s point:

char output[10];

Not long enough.
ReactOS - an Open-source operating system compatible with Windows NT apps and drivers
Advertisement
The itoa function isn''t standard, while sprintf is standard. If you want to go for not-completely-standard, you should use snprintf (it''s ISO but not ANSI); it''s safer that sprintf.

This topic is closed to new replies.

Advertisement