int 转十六进制
2024-10-20 07:46:35
//使用1字节就可以表示b
public static String numToHex8(int b) {
return String.format("%02x", b);//2表示需要两个16进行数
}
//需要使用2字节表示b
public static String numToHex16(int b) {
return String.format("%04x", b);
}
//需要使用4字节表示b
public static String numToHex32(int b) {
return String.format("%08x", b);
}
最新文章
- IOS 杂笔-14(被人遗忘的owner)
- css选择器的使用详解
- 太极旋转-JS实现
- CSS选择器、标签,div的位置。
- easyui treegrid逐步加载
- python2.7之MySQLdb模块 for linux安装
- Find a way——L
- POJ 1961 Period( KMP )*
- 模拟 ACdream 1196 KIDx's Pagination
- nuget.exe the application could not be started
- 写在阿里去IOE一周年
- 监控服务器JVM内存运行
- for xml path以及sql合并查询
- Eclipse使用技巧总结(三)
- 九、Hadoop学习笔记————Hive简介
- lightoj 1025 区间dp
- 4.镜像管理【Docker每天5分钟】
- GDC2017【神秘海域 4】中所使用的顶点着色器技术
- [Codeforces Round #492 (Div. 1) ][B. Suit and Tie]
- MySQL order by的实现
热门文章
- NGINX白名单功能,ngx_http_limit_conn_module和ngx_http_limit_req_module值设置多少才合适呀?
- Linux环境下编译JDK
- eclipse 五种断点
- Css Position定位(简易版本)
- iOS -- SpriteKit框架之SKPhysicsBody的移动和连接
- hdu1827之强联通
- Solidworks输出Autocad的DWG格式乱码怎么办
- hadoop安全之hftp
- python 写数据到txt 文件
- 构建基于Javascript的移动web CMS——Hello,World