整数显示二进制字符串
2010-12-19 13:11
190 查看
function IntToBin(Value: Integer; Count: Integer = 32): string; var iTemp: Integer; begin Result := ''; while Count > 0 do begin iTemp := Value shr (Count - 1) and 1; case iTemp of 1: Result := Result + '1'; 0: Result := Result + '0'; end; Dec(Count); end; end;
相关文章推荐
- c语言整数转二进制显示及统计1的个数
- 二进制长字符串转为大整数(16进制数)
- 大整数 转换为 二进制字符串
- ip字符串转换为 二进制整数
- 【C/C++】获取整数的二进制形式字符串
- 显示一个整数的所有二进制位
- 汇编语言: 编写子程序嵌套结构的程序,把整数分别用二进制和八进制形式显示出来。
- 字符串得到其unicode码的二进制表示(字符串显示),反过来亦可
- Linux下将整数格式化成二进制表示的字符串
- 整数的二进制显示
- Android开发之数字字符串小数为0的直接显示整数工具
- 第二章 Mysql 数据类型简介--(整数类型、浮点数类型和定点数类型,日期与时间类型,字符串类型,二进制类型)
- 对于二进制的字符串进行二进制整数转换,并进行二进制输出,前面补0
- ip字符串转换为 二进制整数
- 每天一道LeetCode-----将用数组表示的整数加一,两个用字符串表示的(二进制)数相加
- 显示整数、浮点数的二进制字节排列函数
- 字符串和二进制数组转换、将HTML文件显示为页面的一部分、UTF8和GB2312之间的转换
- HDU5969 整数转成二进制字符串的方法+思维+贪心
- 将整数转化为二进制字符串
- 【C语言】任意整数转二进制字符串