code: func TritsToTrytes(trits Trits) (Trytes, error) {
  	if !CanTritsToTrytes(trits) {
  		return "", errors.Wrap(ErrInvalidTritsLength, "trits slice size must be a multiple of 3")
  	}
  
  	o := make([]byte, len(trits)/3)
  	for i := 0; i < len(trits)/3; i++ {
  		j := trits[i*3] + trits[i*3+1]*3 + trits[i*3+2]*9
  		if j < 0 {
  			j += int8(len(TryteAlphabet))
  		}
  		o[i] = TryteAlphabet[j]
  	}
  	return Trytes(o), nil
  }
docs: // TritsToTrytes converts a slice of trits into trytes. Returns an error if len(t)%3!=0