整数转字符串和字符串转换为整数

一、编写函数itob(n,s,b),将整数n转换为以b为底的数,并将结果以字符的形式保存到字符串s中。例如,itob(n,s,16)把整数n格式化成十六进制整数保存在s中。 这里我我修改了一下书上提供的答案所使用的do 。。。while循环改为for循环 the c  programming language一书中所给实现源码是: void itob(int n , char s[], int b
相关文章
相关标签/搜索