úÎñµportable experimentalamy@nualeargais.ie Safe-Inferred k2 generates the list of Binary Reflected Gray Code 4 (BRGC) numbers of length k. This code is cyclic.  xs k. generates a non-Boolean (or n-ary) Gray code  of length k using the elements of x as digits. This code is  cyclic. Ex:  "012" 4$ generates a ternary Gray code that  is four digits long. Shift elements right. gray-extended-1.3 Codec.Gray grayCodes naryGrayCodesshiftprefixAndShift