FAQ
you're printing the hex representation of an ascii string. a bit
convoluted, but:

% echo -n 64617461203139 | sed 's/\(..\)/\1 /g' | xargs ascii
  d
  a
  t
  a
sp
  1
  9

from golang.org/pkg/fmt:

String and slice of bytes:

%x base 16, lower-case, two characters per byte
%X base 16, upper-case, two characters per byte

--
You received this message because you are subscribed to the Google Groups "golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Search Discussions

Discussion Posts

Previous

Related Discussions

Discussion Navigation
viewthread | post
posts ‹ prev | 2 of 2 | next ›
Discussion Overview
groupgolang-nuts @
categoriesgo
postedMar 29, '14 at 1:07a
activeMar 29, '14 at 1:14a
posts2
users2
websitegolang.org

2 users in discussion

Andrey mirtchovski: 1 post Bryanturley: 1 post

People

Translate

site design / logo © 2021 Grokbase