Advertisement Jump to content
Sign in to follow this  
Calin

Data Conversion Routines question. *solved*

This topic is 4900 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

char *_itoa( int value, char *string, int radix ); Can someone explain int radix parameter? MSDN doesn`t tell to much. Thanks in advance.

Share this post


Link to post
Share on other sites
Advertisement
IIRC, the radix is the base -- as in, base 2 (binary), base 10 (decimal), base 16 (hexadecimal). Chances are you want 10, decimal.

Share this post


Link to post
Share on other sites
radix is what base to translate the string as. For example it could be octal, where the legitmate digits are from 0 to 7, or it could decimal, where the legitimate digits are 0 to 9, or it could be hexidecimal where the legitmate digits are from 0 to F. In those cases you would use a radix of 8, 10 and 16 respectively.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!