yzhch

 

关于Uinit8和Byte:

The Go Programming Language Specification Numeric types

uint8 the set of all unsigned 8-bit integers (0 to 255)

byte alias for uint8

 

将[]uinit8转换为string:

func B2S(bs []int8) string {
  ba := []byte{}
  for _, b := range bs {
    ba = append(ba, byte(b))
  }
  return string(ba)
}

 

参考文章:

https://blog.csdn.net/pingD/article/details/76588648

 

分类:

技术点:

相关文章:

  • 2022-02-06
  • 2021-07-01
  • 2021-07-15
  • 2021-10-10
  • 2021-11-03
  • 2022-12-23
猜你喜欢
  • 2021-08-09
  • 2022-12-23
  • 2021-08-01
  • 2021-12-13
  • 2021-09-23
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案