package test01 import ( "bytes" "encoding/binary" "fmt" "os" ) func IntToByte(num int64) []byte { var buffer bytes.Buffer err := binary.Write(&buffer, binary.BigEndian, < |
Golang IntToByte 实现
最新推荐文章于 2024-06-08 21:23:25 发布
![](https://img-home.csdnimg.cn/images/20240711042549.png)
package test01 import ( "bytes" "encoding/binary" "fmt" "os" ) func IntToByte(num int64) []byte { var buffer bytes.Buffer err := binary.Write(&buffer, binary.BigEndian, < |