golang int to fixed length byte array code example Example: golang convert fix length byte array to slices b := a[:] // Same as b := a[0:len(a)]