diff options
-rw-r--r-- | lib/hex.go | 9 |
1 files changed, 9 insertions, 0 deletions
@@ -66,3 +66,12 @@ func ByteToHexStr(b byte) string { return s } + +func BytesToHexStr(bs []byte) string { + hs := "" + + for i := 0; i < len(bs); i++ { + hs += " " + ByteToHexStr(bs[i]) + } + return hs +} |