func (nxts NibbleXORTables) Serialize() []byte { dst, base := make([]byte, nxtsSize), 0 for _, rack := range nxts { for _, xorTable := range rack { base += copy(dst[base:], table.SerializeNibble(xorTable)) } } return dst }
func serializeXORTables(dst []byte, t [9][32][3]table.Nibble) int { base := 0 for _, round := range t { for _, pos := range round { for _, gate := range pos { base += copy(dst[base:], table.SerializeNibble(gate)) } } } return base }