Identifier
Identifier
Mp00131: Permutations descent bottomsBinary words
Images
[1] =>
[1,2] => 0
[2,1] => 1
[1,2,3] => 00
[1,3,2] => 01
[2,1,3] => 10
[2,3,1] => 10
[3,1,2] => 10
[3,2,1] => 11
[1,2,3,4] => 000
[1,2,4,3] => 001
[1,3,2,4] => 010
[1,3,4,2] => 010
[1,4,2,3] => 010
[1,4,3,2] => 011
[2,1,3,4] => 100
[2,1,4,3] => 101
[2,3,1,4] => 100
[2,3,4,1] => 100
[2,4,1,3] => 100
[2,4,3,1] => 101
[3,1,2,4] => 100
[3,1,4,2] => 110
[3,2,1,4] => 110
[3,2,4,1] => 110
[3,4,1,2] => 100
[3,4,2,1] => 110
[4,1,2,3] => 100
[4,1,3,2] => 110
[4,2,1,3] => 110
[4,2,3,1] => 110
[4,3,1,2] => 101
[4,3,2,1] => 111
[1,2,3,4,5] => 0000
[1,2,3,5,4] => 0001
[1,2,4,3,5] => 0010
[1,2,4,5,3] => 0010
[1,2,5,3,4] => 0010
[1,2,5,4,3] => 0011
[1,3,2,4,5] => 0100
[1,3,2,5,4] => 0101
[1,3,4,2,5] => 0100
[1,3,4,5,2] => 0100
[1,3,5,2,4] => 0100
[1,3,5,4,2] => 0101
[1,4,2,3,5] => 0100
[1,4,2,5,3] => 0110
[1,4,3,2,5] => 0110
[1,4,3,5,2] => 0110
[1,4,5,2,3] => 0100
[1,4,5,3,2] => 0110
[1,5,2,3,4] => 0100
[1,5,2,4,3] => 0110
[1,5,3,2,4] => 0110
[1,5,3,4,2] => 0110
[1,5,4,2,3] => 0101
[1,5,4,3,2] => 0111
[2,1,3,4,5] => 1000
[2,1,3,5,4] => 1001
[2,1,4,3,5] => 1010
[2,1,4,5,3] => 1010
[2,1,5,3,4] => 1010
[2,1,5,4,3] => 1011
[2,3,1,4,5] => 1000
[2,3,1,5,4] => 1001
[2,3,4,1,5] => 1000
[2,3,4,5,1] => 1000
[2,3,5,1,4] => 1000
[2,3,5,4,1] => 1001
[2,4,1,3,5] => 1000
[2,4,1,5,3] => 1010
[2,4,3,1,5] => 1010
[2,4,3,5,1] => 1010
[2,4,5,1,3] => 1000
[2,4,5,3,1] => 1010
[2,5,1,3,4] => 1000
[2,5,1,4,3] => 1010
[2,5,3,1,4] => 1010
[2,5,3,4,1] => 1010
[2,5,4,1,3] => 1001
[2,5,4,3,1] => 1011
[3,1,2,4,5] => 1000
[3,1,2,5,4] => 1001
[3,1,4,2,5] => 1100
[3,1,4,5,2] => 1100
[3,1,5,2,4] => 1100
[3,1,5,4,2] => 1101
[3,2,1,4,5] => 1100
[3,2,1,5,4] => 1101
[3,2,4,1,5] => 1100
[3,2,4,5,1] => 1100
[3,2,5,1,4] => 1100
[3,2,5,4,1] => 1101
[3,4,1,2,5] => 1000
[3,4,1,5,2] => 1100
[3,4,2,1,5] => 1100
[3,4,2,5,1] => 1100
[3,4,5,1,2] => 1000
[3,4,5,2,1] => 1100
[3,5,1,2,4] => 1000
[3,5,1,4,2] => 1100
[3,5,2,1,4] => 1100
[3,5,2,4,1] => 1100
[3,5,4,1,2] => 1001
[3,5,4,2,1] => 1101
[4,1,2,3,5] => 1000
[4,1,2,5,3] => 1010
[4,1,3,2,5] => 1100
[4,1,3,5,2] => 1100
[4,1,5,2,3] => 1100
[4,1,5,3,2] => 1110
[4,2,1,3,5] => 1100
[4,2,1,5,3] => 1110
[4,2,3,1,5] => 1100
[4,2,3,5,1] => 1100
[4,2,5,1,3] => 1100
[4,2,5,3,1] => 1110
[4,3,1,2,5] => 1010
[4,3,1,5,2] => 1110
[4,3,2,1,5] => 1110
[4,3,2,5,1] => 1110
[4,3,5,1,2] => 1010
[4,3,5,2,1] => 1110
[4,5,1,2,3] => 1000
[4,5,1,3,2] => 1100
[4,5,2,1,3] => 1100
[4,5,2,3,1] => 1100
[4,5,3,1,2] => 1010
[4,5,3,2,1] => 1110
[5,1,2,3,4] => 1000
[5,1,2,4,3] => 1010
[5,1,3,2,4] => 1100
[5,1,3,4,2] => 1100
[5,1,4,2,3] => 1100
[5,1,4,3,2] => 1110
[5,2,1,3,4] => 1100
[5,2,1,4,3] => 1110
[5,2,3,1,4] => 1100
[5,2,3,4,1] => 1100
[5,2,4,1,3] => 1100
[5,2,4,3,1] => 1110
[5,3,1,2,4] => 1010
[5,3,1,4,2] => 1110
[5,3,2,1,4] => 1110
[5,3,2,4,1] => 1110
[5,3,4,1,2] => 1010
[5,3,4,2,1] => 1110
[5,4,1,2,3] => 1001
[5,4,1,3,2] => 1101
[5,4,2,1,3] => 1101
[5,4,2,3,1] => 1101
[5,4,3,1,2] => 1011
[5,4,3,2,1] => 1111
[1,2,3,4,5,6] => 00000
[1,2,3,4,6,5] => 00001
[1,2,3,5,4,6] => 00010
[1,2,3,5,6,4] => 00010
[1,2,3,6,4,5] => 00010
[1,2,3,6,5,4] => 00011
[1,2,4,3,5,6] => 00100
[1,2,4,3,6,5] => 00101
[1,2,4,5,3,6] => 00100
[1,2,4,5,6,3] => 00100
[1,2,4,6,3,5] => 00100
[1,2,4,6,5,3] => 00101
[1,2,5,3,4,6] => 00100
[1,2,5,3,6,4] => 00110
[1,2,5,4,3,6] => 00110
[1,2,5,4,6,3] => 00110
[1,2,5,6,3,4] => 00100
[1,2,5,6,4,3] => 00110
[1,2,6,3,4,5] => 00100
[1,2,6,3,5,4] => 00110
[1,2,6,4,3,5] => 00110
[1,2,6,4,5,3] => 00110
[1,2,6,5,3,4] => 00101
[1,2,6,5,4,3] => 00111
[1,3,2,4,5,6] => 01000
[1,3,2,4,6,5] => 01001
[1,3,2,5,4,6] => 01010
[1,3,2,5,6,4] => 01010
[1,3,2,6,4,5] => 01010
[1,3,2,6,5,4] => 01011
[1,3,4,2,5,6] => 01000
[1,3,4,2,6,5] => 01001
[1,3,4,5,2,6] => 01000
[1,3,4,5,6,2] => 01000
[1,3,4,6,2,5] => 01000
[1,3,4,6,5,2] => 01001
[1,3,5,2,4,6] => 01000
[1,3,5,2,6,4] => 01010
[1,3,5,4,2,6] => 01010
[1,3,5,4,6,2] => 01010
[1,3,5,6,2,4] => 01000
[1,3,5,6,4,2] => 01010
[1,3,6,2,4,5] => 01000
[1,3,6,2,5,4] => 01010
[1,3,6,4,2,5] => 01010
[1,3,6,4,5,2] => 01010
[1,3,6,5,2,4] => 01001
[1,3,6,5,4,2] => 01011
[1,4,2,3,5,6] => 01000
[1,4,2,3,6,5] => 01001
[1,4,2,5,3,6] => 01100
[1,4,2,5,6,3] => 01100
[1,4,2,6,3,5] => 01100
[1,4,2,6,5,3] => 01101
[1,4,3,2,5,6] => 01100
[1,4,3,2,6,5] => 01101
[1,4,3,5,2,6] => 01100
[1,4,3,5,6,2] => 01100
[1,4,3,6,2,5] => 01100
[1,4,3,6,5,2] => 01101
[1,4,5,2,3,6] => 01000
[1,4,5,2,6,3] => 01100
[1,4,5,3,2,6] => 01100
[1,4,5,3,6,2] => 01100
[1,4,5,6,2,3] => 01000
[1,4,5,6,3,2] => 01100
[1,4,6,2,3,5] => 01000
[1,4,6,2,5,3] => 01100
[1,4,6,3,2,5] => 01100
[1,4,6,3,5,2] => 01100
[1,4,6,5,2,3] => 01001
[1,4,6,5,3,2] => 01101
[1,5,2,3,4,6] => 01000
[1,5,2,3,6,4] => 01010
[1,5,2,4,3,6] => 01100
[1,5,2,4,6,3] => 01100
[1,5,2,6,3,4] => 01100
[1,5,2,6,4,3] => 01110
[1,5,3,2,4,6] => 01100
[1,5,3,2,6,4] => 01110
[1,5,3,4,2,6] => 01100
[1,5,3,4,6,2] => 01100
[1,5,3,6,2,4] => 01100
[1,5,3,6,4,2] => 01110
[1,5,4,2,3,6] => 01010
[1,5,4,2,6,3] => 01110
[1,5,4,3,2,6] => 01110
[1,5,4,3,6,2] => 01110
[1,5,4,6,2,3] => 01010
[1,5,4,6,3,2] => 01110
[1,5,6,2,3,4] => 01000
[1,5,6,2,4,3] => 01100
[1,5,6,3,2,4] => 01100
[1,5,6,3,4,2] => 01100
[1,5,6,4,2,3] => 01010
[1,5,6,4,3,2] => 01110
[1,6,2,3,4,5] => 01000
[1,6,2,3,5,4] => 01010
[1,6,2,4,3,5] => 01100
[1,6,2,4,5,3] => 01100
[1,6,2,5,3,4] => 01100
[1,6,2,5,4,3] => 01110
[1,6,3,2,4,5] => 01100
[1,6,3,2,5,4] => 01110
[1,6,3,4,2,5] => 01100
[1,6,3,4,5,2] => 01100
[1,6,3,5,2,4] => 01100
[1,6,3,5,4,2] => 01110
[1,6,4,2,3,5] => 01010
[1,6,4,2,5,3] => 01110
[1,6,4,3,2,5] => 01110
[1,6,4,3,5,2] => 01110
[1,6,4,5,2,3] => 01010
[1,6,4,5,3,2] => 01110
[1,6,5,2,3,4] => 01001
[1,6,5,2,4,3] => 01101
[1,6,5,3,2,4] => 01101
[1,6,5,3,4,2] => 01101
[1,6,5,4,2,3] => 01011
[1,6,5,4,3,2] => 01111
[2,1,3,4,5,6] => 10000
[2,1,3,4,6,5] => 10001
[2,1,3,5,4,6] => 10010
[2,1,3,5,6,4] => 10010
[2,1,3,6,4,5] => 10010
[2,1,3,6,5,4] => 10011
[2,1,4,3,5,6] => 10100
[2,1,4,3,6,5] => 10101
[2,1,4,5,3,6] => 10100
[2,1,4,5,6,3] => 10100
[2,1,4,6,3,5] => 10100
[2,1,4,6,5,3] => 10101
[2,1,5,3,4,6] => 10100
[2,1,5,3,6,4] => 10110
[2,1,5,4,3,6] => 10110
[2,1,5,4,6,3] => 10110
[2,1,5,6,3,4] => 10100
[2,1,5,6,4,3] => 10110
[2,1,6,3,4,5] => 10100
[2,1,6,3,5,4] => 10110
[2,1,6,4,3,5] => 10110
[2,1,6,4,5,3] => 10110
[2,1,6,5,3,4] => 10101
[2,1,6,5,4,3] => 10111
[2,3,1,4,5,6] => 10000
[2,3,1,4,6,5] => 10001
[2,3,1,5,4,6] => 10010
[2,3,1,5,6,4] => 10010
[2,3,1,6,4,5] => 10010
[2,3,1,6,5,4] => 10011
[2,3,4,1,5,6] => 10000
[2,3,4,1,6,5] => 10001
[2,3,4,5,1,6] => 10000
[2,3,4,5,6,1] => 10000
[2,3,4,6,1,5] => 10000
[2,3,4,6,5,1] => 10001
[2,3,5,1,4,6] => 10000
[2,3,5,1,6,4] => 10010
[2,3,5,4,1,6] => 10010
[2,3,5,4,6,1] => 10010
[2,3,5,6,1,4] => 10000
[2,3,5,6,4,1] => 10010
[2,3,6,1,4,5] => 10000
[2,3,6,1,5,4] => 10010
[2,3,6,4,1,5] => 10010
[2,3,6,4,5,1] => 10010
[2,3,6,5,1,4] => 10001
[2,3,6,5,4,1] => 10011
[2,4,1,3,5,6] => 10000
[2,4,1,3,6,5] => 10001
[2,4,1,5,3,6] => 10100
[2,4,1,5,6,3] => 10100
[2,4,1,6,3,5] => 10100
[2,4,1,6,5,3] => 10101
[2,4,3,1,5,6] => 10100
[2,4,3,1,6,5] => 10101
[2,4,3,5,1,6] => 10100
[2,4,3,5,6,1] => 10100
[2,4,3,6,1,5] => 10100
[2,4,3,6,5,1] => 10101
[2,4,5,1,3,6] => 10000
[2,4,5,1,6,3] => 10100
[2,4,5,3,1,6] => 10100
[2,4,5,3,6,1] => 10100
[2,4,5,6,1,3] => 10000
[2,4,5,6,3,1] => 10100
[2,4,6,1,3,5] => 10000
[2,4,6,1,5,3] => 10100
[2,4,6,3,1,5] => 10100
[2,4,6,3,5,1] => 10100
[2,4,6,5,1,3] => 10001
[2,4,6,5,3,1] => 10101
[2,5,1,3,4,6] => 10000
[2,5,1,3,6,4] => 10010
[2,5,1,4,3,6] => 10100
[2,5,1,4,6,3] => 10100
[2,5,1,6,3,4] => 10100
[2,5,1,6,4,3] => 10110
[2,5,3,1,4,6] => 10100
[2,5,3,1,6,4] => 10110
[2,5,3,4,1,6] => 10100
[2,5,3,4,6,1] => 10100
[2,5,3,6,1,4] => 10100
[2,5,3,6,4,1] => 10110
[2,5,4,1,3,6] => 10010
[2,5,4,1,6,3] => 10110
[2,5,4,3,1,6] => 10110
[2,5,4,3,6,1] => 10110
[2,5,4,6,1,3] => 10010
[2,5,4,6,3,1] => 10110
[2,5,6,1,3,4] => 10000
[2,5,6,1,4,3] => 10100
[2,5,6,3,1,4] => 10100
[2,5,6,3,4,1] => 10100
[2,5,6,4,1,3] => 10010
[2,5,6,4,3,1] => 10110
[2,6,1,3,4,5] => 10000
[2,6,1,3,5,4] => 10010
[2,6,1,4,3,5] => 10100
[2,6,1,4,5,3] => 10100
[2,6,1,5,3,4] => 10100
[2,6,1,5,4,3] => 10110
[2,6,3,1,4,5] => 10100
[2,6,3,1,5,4] => 10110
[2,6,3,4,1,5] => 10100
[2,6,3,4,5,1] => 10100
[2,6,3,5,1,4] => 10100
[2,6,3,5,4,1] => 10110
[2,6,4,1,3,5] => 10010
[2,6,4,1,5,3] => 10110
[2,6,4,3,1,5] => 10110
[2,6,4,3,5,1] => 10110
[2,6,4,5,1,3] => 10010
[2,6,4,5,3,1] => 10110
[2,6,5,1,3,4] => 10001
[2,6,5,1,4,3] => 10101
[2,6,5,3,1,4] => 10101
[2,6,5,3,4,1] => 10101
[2,6,5,4,1,3] => 10011
[2,6,5,4,3,1] => 10111
[3,1,2,4,5,6] => 10000
[3,1,2,4,6,5] => 10001
[3,1,2,5,4,6] => 10010
[3,1,2,5,6,4] => 10010
[3,1,2,6,4,5] => 10010
[3,1,2,6,5,4] => 10011
[3,1,4,2,5,6] => 11000
[3,1,4,2,6,5] => 11001
[3,1,4,5,2,6] => 11000
[3,1,4,5,6,2] => 11000
[3,1,4,6,2,5] => 11000
[3,1,4,6,5,2] => 11001
[3,1,5,2,4,6] => 11000
[3,1,5,2,6,4] => 11010
[3,1,5,4,2,6] => 11010
[3,1,5,4,6,2] => 11010
[3,1,5,6,2,4] => 11000
[3,1,5,6,4,2] => 11010
[3,1,6,2,4,5] => 11000
[3,1,6,2,5,4] => 11010
[3,1,6,4,2,5] => 11010
[3,1,6,4,5,2] => 11010
[3,1,6,5,2,4] => 11001
[3,1,6,5,4,2] => 11011
[3,2,1,4,5,6] => 11000
[3,2,1,4,6,5] => 11001
[3,2,1,5,4,6] => 11010
[3,2,1,5,6,4] => 11010
[3,2,1,6,4,5] => 11010
[3,2,1,6,5,4] => 11011
[3,2,4,1,5,6] => 11000
[3,2,4,1,6,5] => 11001
[3,2,4,5,1,6] => 11000
[3,2,4,5,6,1] => 11000
[3,2,4,6,1,5] => 11000
[3,2,4,6,5,1] => 11001
[3,2,5,1,4,6] => 11000
[3,2,5,1,6,4] => 11010
[3,2,5,4,1,6] => 11010
[3,2,5,4,6,1] => 11010
[3,2,5,6,1,4] => 11000
[3,2,5,6,4,1] => 11010
[3,2,6,1,4,5] => 11000
[3,2,6,1,5,4] => 11010
[3,2,6,4,1,5] => 11010
[3,2,6,4,5,1] => 11010
[3,2,6,5,1,4] => 11001
[3,2,6,5,4,1] => 11011
[3,4,1,2,5,6] => 10000
[3,4,1,2,6,5] => 10001
[3,4,1,5,2,6] => 11000
[3,4,1,5,6,2] => 11000
[3,4,1,6,2,5] => 11000
[3,4,1,6,5,2] => 11001
[3,4,2,1,5,6] => 11000
[3,4,2,1,6,5] => 11001
[3,4,2,5,1,6] => 11000
[3,4,2,5,6,1] => 11000
[3,4,2,6,1,5] => 11000
[3,4,2,6,5,1] => 11001
[3,4,5,1,2,6] => 10000
[3,4,5,1,6,2] => 11000
[3,4,5,2,1,6] => 11000
[3,4,5,2,6,1] => 11000
[3,4,5,6,1,2] => 10000
[3,4,5,6,2,1] => 11000
[3,4,6,1,2,5] => 10000
[3,4,6,1,5,2] => 11000
[3,4,6,2,1,5] => 11000
[3,4,6,2,5,1] => 11000
[3,4,6,5,1,2] => 10001
[3,4,6,5,2,1] => 11001
[3,5,1,2,4,6] => 10000
[3,5,1,2,6,4] => 10010
[3,5,1,4,2,6] => 11000
[3,5,1,4,6,2] => 11000
[3,5,1,6,2,4] => 11000
[3,5,1,6,4,2] => 11010
[3,5,2,1,4,6] => 11000
[3,5,2,1,6,4] => 11010
[3,5,2,4,1,6] => 11000
[3,5,2,4,6,1] => 11000
[3,5,2,6,1,4] => 11000
[3,5,2,6,4,1] => 11010
[3,5,4,1,2,6] => 10010
[3,5,4,1,6,2] => 11010
[3,5,4,2,1,6] => 11010
[3,5,4,2,6,1] => 11010
[3,5,4,6,1,2] => 10010
[3,5,4,6,2,1] => 11010
[3,5,6,1,2,4] => 10000
[3,5,6,1,4,2] => 11000
[3,5,6,2,1,4] => 11000
[3,5,6,2,4,1] => 11000
[3,5,6,4,1,2] => 10010
[3,5,6,4,2,1] => 11010
[3,6,1,2,4,5] => 10000
[3,6,1,2,5,4] => 10010
[3,6,1,4,2,5] => 11000
[3,6,1,4,5,2] => 11000
[3,6,1,5,2,4] => 11000
[3,6,1,5,4,2] => 11010
[3,6,2,1,4,5] => 11000
[3,6,2,1,5,4] => 11010
[3,6,2,4,1,5] => 11000
[3,6,2,4,5,1] => 11000
[3,6,2,5,1,4] => 11000
[3,6,2,5,4,1] => 11010
[3,6,4,1,2,5] => 10010
[3,6,4,1,5,2] => 11010
[3,6,4,2,1,5] => 11010
[3,6,4,2,5,1] => 11010
[3,6,4,5,1,2] => 10010
[3,6,4,5,2,1] => 11010
[3,6,5,1,2,4] => 10001
[3,6,5,1,4,2] => 11001
[3,6,5,2,1,4] => 11001
[3,6,5,2,4,1] => 11001
[3,6,5,4,1,2] => 10011
[3,6,5,4,2,1] => 11011
[4,1,2,3,5,6] => 10000
[4,1,2,3,6,5] => 10001
[4,1,2,5,3,6] => 10100
[4,1,2,5,6,3] => 10100
[4,1,2,6,3,5] => 10100
[4,1,2,6,5,3] => 10101
[4,1,3,2,5,6] => 11000
[4,1,3,2,6,5] => 11001
[4,1,3,5,2,6] => 11000
[4,1,3,5,6,2] => 11000
[4,1,3,6,2,5] => 11000
[4,1,3,6,5,2] => 11001
[4,1,5,2,3,6] => 11000
[4,1,5,2,6,3] => 11100
[4,1,5,3,2,6] => 11100
[4,1,5,3,6,2] => 11100
[4,1,5,6,2,3] => 11000
[4,1,5,6,3,2] => 11100
[4,1,6,2,3,5] => 11000
[4,1,6,2,5,3] => 11100
[4,1,6,3,2,5] => 11100
[4,1,6,3,5,2] => 11100
[4,1,6,5,2,3] => 11001
[4,1,6,5,3,2] => 11101
[4,2,1,3,5,6] => 11000
[4,2,1,3,6,5] => 11001
[4,2,1,5,3,6] => 11100
[4,2,1,5,6,3] => 11100
[4,2,1,6,3,5] => 11100
[4,2,1,6,5,3] => 11101
[4,2,3,1,5,6] => 11000
[4,2,3,1,6,5] => 11001
[4,2,3,5,1,6] => 11000
[4,2,3,5,6,1] => 11000
[4,2,3,6,1,5] => 11000
[4,2,3,6,5,1] => 11001
[4,2,5,1,3,6] => 11000
[4,2,5,1,6,3] => 11100
[4,2,5,3,1,6] => 11100
[4,2,5,3,6,1] => 11100
[4,2,5,6,1,3] => 11000
[4,2,5,6,3,1] => 11100
[4,2,6,1,3,5] => 11000
[4,2,6,1,5,3] => 11100
[4,2,6,3,1,5] => 11100
[4,2,6,3,5,1] => 11100
[4,2,6,5,1,3] => 11001
[4,2,6,5,3,1] => 11101
[4,3,1,2,5,6] => 10100
[4,3,1,2,6,5] => 10101
[4,3,1,5,2,6] => 11100
[4,3,1,5,6,2] => 11100
[4,3,1,6,2,5] => 11100
[4,3,1,6,5,2] => 11101
[4,3,2,1,5,6] => 11100
[4,3,2,1,6,5] => 11101
[4,3,2,5,1,6] => 11100
[4,3,2,5,6,1] => 11100
[4,3,2,6,1,5] => 11100
[4,3,2,6,5,1] => 11101
[4,3,5,1,2,6] => 10100
[4,3,5,1,6,2] => 11100
[4,3,5,2,1,6] => 11100
[4,3,5,2,6,1] => 11100
[4,3,5,6,1,2] => 10100
[4,3,5,6,2,1] => 11100
[4,3,6,1,2,5] => 10100
[4,3,6,1,5,2] => 11100
[4,3,6,2,1,5] => 11100
[4,3,6,2,5,1] => 11100
[4,3,6,5,1,2] => 10101
[4,3,6,5,2,1] => 11101
[4,5,1,2,3,6] => 10000
[4,5,1,2,6,3] => 10100
[4,5,1,3,2,6] => 11000
[4,5,1,3,6,2] => 11000
[4,5,1,6,2,3] => 11000
[4,5,1,6,3,2] => 11100
[4,5,2,1,3,6] => 11000
[4,5,2,1,6,3] => 11100
[4,5,2,3,1,6] => 11000
[4,5,2,3,6,1] => 11000
[4,5,2,6,1,3] => 11000
[4,5,2,6,3,1] => 11100
[4,5,3,1,2,6] => 10100
[4,5,3,1,6,2] => 11100
[4,5,3,2,1,6] => 11100
[4,5,3,2,6,1] => 11100
[4,5,3,6,1,2] => 10100
[4,5,3,6,2,1] => 11100
[4,5,6,1,2,3] => 10000
[4,5,6,1,3,2] => 11000
[4,5,6,2,1,3] => 11000
[4,5,6,2,3,1] => 11000
[4,5,6,3,1,2] => 10100
[4,5,6,3,2,1] => 11100
[4,6,1,2,3,5] => 10000
[4,6,1,2,5,3] => 10100
[4,6,1,3,2,5] => 11000
[4,6,1,3,5,2] => 11000
[4,6,1,5,2,3] => 11000
[4,6,1,5,3,2] => 11100
[4,6,2,1,3,5] => 11000
[4,6,2,1,5,3] => 11100
[4,6,2,3,1,5] => 11000
[4,6,2,3,5,1] => 11000
[4,6,2,5,1,3] => 11000
[4,6,2,5,3,1] => 11100
[4,6,3,1,2,5] => 10100
[4,6,3,1,5,2] => 11100
[4,6,3,2,1,5] => 11100
[4,6,3,2,5,1] => 11100
[4,6,3,5,1,2] => 10100
[4,6,3,5,2,1] => 11100
[4,6,5,1,2,3] => 10001
[4,6,5,1,3,2] => 11001
[4,6,5,2,1,3] => 11001
[4,6,5,2,3,1] => 11001
[4,6,5,3,1,2] => 10101
[4,6,5,3,2,1] => 11101
[5,1,2,3,4,6] => 10000
[5,1,2,3,6,4] => 10010
[5,1,2,4,3,6] => 10100
[5,1,2,4,6,3] => 10100
[5,1,2,6,3,4] => 10100
[5,1,2,6,4,3] => 10110
[5,1,3,2,4,6] => 11000
[5,1,3,2,6,4] => 11010
[5,1,3,4,2,6] => 11000
[5,1,3,4,6,2] => 11000
[5,1,3,6,2,4] => 11000
[5,1,3,6,4,2] => 11010
[5,1,4,2,3,6] => 11000
[5,1,4,2,6,3] => 11100
[5,1,4,3,2,6] => 11100
[5,1,4,3,6,2] => 11100
[5,1,4,6,2,3] => 11000
[5,1,4,6,3,2] => 11100
[5,1,6,2,3,4] => 11000
[5,1,6,2,4,3] => 11100
[5,1,6,3,2,4] => 11100
[5,1,6,3,4,2] => 11100
[5,1,6,4,2,3] => 11010
[5,1,6,4,3,2] => 11110
[5,2,1,3,4,6] => 11000
[5,2,1,3,6,4] => 11010
[5,2,1,4,3,6] => 11100
[5,2,1,4,6,3] => 11100
[5,2,1,6,3,4] => 11100
[5,2,1,6,4,3] => 11110
[5,2,3,1,4,6] => 11000
[5,2,3,1,6,4] => 11010
[5,2,3,4,1,6] => 11000
[5,2,3,4,6,1] => 11000
[5,2,3,6,1,4] => 11000
[5,2,3,6,4,1] => 11010
[5,2,4,1,3,6] => 11000
[5,2,4,1,6,3] => 11100
[5,2,4,3,1,6] => 11100
[5,2,4,3,6,1] => 11100
[5,2,4,6,1,3] => 11000
[5,2,4,6,3,1] => 11100
[5,2,6,1,3,4] => 11000
[5,2,6,1,4,3] => 11100
[5,2,6,3,1,4] => 11100
[5,2,6,3,4,1] => 11100
[5,2,6,4,1,3] => 11010
[5,2,6,4,3,1] => 11110
[5,3,1,2,4,6] => 10100
[5,3,1,2,6,4] => 10110
[5,3,1,4,2,6] => 11100
[5,3,1,4,6,2] => 11100
[5,3,1,6,2,4] => 11100
[5,3,1,6,4,2] => 11110
[5,3,2,1,4,6] => 11100
[5,3,2,1,6,4] => 11110
[5,3,2,4,1,6] => 11100
[5,3,2,4,6,1] => 11100
[5,3,2,6,1,4] => 11100
[5,3,2,6,4,1] => 11110
[5,3,4,1,2,6] => 10100
[5,3,4,1,6,2] => 11100
[5,3,4,2,1,6] => 11100
[5,3,4,2,6,1] => 11100
[5,3,4,6,1,2] => 10100
[5,3,4,6,2,1] => 11100
[5,3,6,1,2,4] => 10100
[5,3,6,1,4,2] => 11100
[5,3,6,2,1,4] => 11100
[5,3,6,2,4,1] => 11100
[5,3,6,4,1,2] => 10110
[5,3,6,4,2,1] => 11110
[5,4,1,2,3,6] => 10010
[5,4,1,2,6,3] => 10110
[5,4,1,3,2,6] => 11010
[5,4,1,3,6,2] => 11010
[5,4,1,6,2,3] => 11010
[5,4,1,6,3,2] => 11110
[5,4,2,1,3,6] => 11010
[5,4,2,1,6,3] => 11110
[5,4,2,3,1,6] => 11010
[5,4,2,3,6,1] => 11010
[5,4,2,6,1,3] => 11010
[5,4,2,6,3,1] => 11110
[5,4,3,1,2,6] => 10110
[5,4,3,1,6,2] => 11110
[5,4,3,2,1,6] => 11110
[5,4,3,2,6,1] => 11110
[5,4,3,6,1,2] => 10110
[5,4,3,6,2,1] => 11110
[5,4,6,1,2,3] => 10010
[5,4,6,1,3,2] => 11010
[5,4,6,2,1,3] => 11010
[5,4,6,2,3,1] => 11010
[5,4,6,3,1,2] => 10110
[5,4,6,3,2,1] => 11110
[5,6,1,2,3,4] => 10000
[5,6,1,2,4,3] => 10100
[5,6,1,3,2,4] => 11000
[5,6,1,3,4,2] => 11000
[5,6,1,4,2,3] => 11000
[5,6,1,4,3,2] => 11100
[5,6,2,1,3,4] => 11000
[5,6,2,1,4,3] => 11100
[5,6,2,3,1,4] => 11000
[5,6,2,3,4,1] => 11000
[5,6,2,4,1,3] => 11000
[5,6,2,4,3,1] => 11100
[5,6,3,1,2,4] => 10100
[5,6,3,1,4,2] => 11100
[5,6,3,2,1,4] => 11100
[5,6,3,2,4,1] => 11100
[5,6,3,4,1,2] => 10100
[5,6,3,4,2,1] => 11100
[5,6,4,1,2,3] => 10010
[5,6,4,1,3,2] => 11010
[5,6,4,2,1,3] => 11010
[5,6,4,2,3,1] => 11010
[5,6,4,3,1,2] => 10110
[5,6,4,3,2,1] => 11110
[6,1,2,3,4,5] => 10000
[6,1,2,3,5,4] => 10010
[6,1,2,4,3,5] => 10100
[6,1,2,4,5,3] => 10100
[6,1,2,5,3,4] => 10100
[6,1,2,5,4,3] => 10110
[6,1,3,2,4,5] => 11000
[6,1,3,2,5,4] => 11010
[6,1,3,4,2,5] => 11000
[6,1,3,4,5,2] => 11000
[6,1,3,5,2,4] => 11000
[6,1,3,5,4,2] => 11010
[6,1,4,2,3,5] => 11000
[6,1,4,2,5,3] => 11100
[6,1,4,3,2,5] => 11100
[6,1,4,3,5,2] => 11100
[6,1,4,5,2,3] => 11000
[6,1,4,5,3,2] => 11100
[6,1,5,2,3,4] => 11000
[6,1,5,2,4,3] => 11100
[6,1,5,3,2,4] => 11100
[6,1,5,3,4,2] => 11100
[6,1,5,4,2,3] => 11010
[6,1,5,4,3,2] => 11110
[6,2,1,3,4,5] => 11000
[6,2,1,3,5,4] => 11010
[6,2,1,4,3,5] => 11100
[6,2,1,4,5,3] => 11100
[6,2,1,5,3,4] => 11100
[6,2,1,5,4,3] => 11110
[6,2,3,1,4,5] => 11000
[6,2,3,1,5,4] => 11010
[6,2,3,4,1,5] => 11000
[6,2,3,4,5,1] => 11000
[6,2,3,5,1,4] => 11000
[6,2,3,5,4,1] => 11010
[6,2,4,1,3,5] => 11000
[6,2,4,1,5,3] => 11100
[6,2,4,3,1,5] => 11100
[6,2,4,3,5,1] => 11100
[6,2,4,5,1,3] => 11000
[6,2,4,5,3,1] => 11100
[6,2,5,1,3,4] => 11000
[6,2,5,1,4,3] => 11100
[6,2,5,3,1,4] => 11100
[6,2,5,3,4,1] => 11100
[6,2,5,4,1,3] => 11010
[6,2,5,4,3,1] => 11110
[6,3,1,2,4,5] => 10100
[6,3,1,2,5,4] => 10110
[6,3,1,4,2,5] => 11100
[6,3,1,4,5,2] => 11100
[6,3,1,5,2,4] => 11100
[6,3,1,5,4,2] => 11110
[6,3,2,1,4,5] => 11100
[6,3,2,1,5,4] => 11110
[6,3,2,4,1,5] => 11100
[6,3,2,4,5,1] => 11100
[6,3,2,5,1,4] => 11100
[6,3,2,5,4,1] => 11110
[6,3,4,1,2,5] => 10100
[6,3,4,1,5,2] => 11100
[6,3,4,2,1,5] => 11100
[6,3,4,2,5,1] => 11100
[6,3,4,5,1,2] => 10100
[6,3,4,5,2,1] => 11100
[6,3,5,1,2,4] => 10100
[6,3,5,1,4,2] => 11100
[6,3,5,2,1,4] => 11100
[6,3,5,2,4,1] => 11100
[6,3,5,4,1,2] => 10110
[6,3,5,4,2,1] => 11110
[6,4,1,2,3,5] => 10010
[6,4,1,2,5,3] => 10110
[6,4,1,3,2,5] => 11010
[6,4,1,3,5,2] => 11010
[6,4,1,5,2,3] => 11010
[6,4,1,5,3,2] => 11110
[6,4,2,1,3,5] => 11010
[6,4,2,1,5,3] => 11110
[6,4,2,3,1,5] => 11010
[6,4,2,3,5,1] => 11010
[6,4,2,5,1,3] => 11010
[6,4,2,5,3,1] => 11110
[6,4,3,1,2,5] => 10110
[6,4,3,1,5,2] => 11110
[6,4,3,2,1,5] => 11110
[6,4,3,2,5,1] => 11110
[6,4,3,5,1,2] => 10110
[6,4,3,5,2,1] => 11110
[6,4,5,1,2,3] => 10010
[6,4,5,1,3,2] => 11010
[6,4,5,2,1,3] => 11010
[6,4,5,2,3,1] => 11010
[6,4,5,3,1,2] => 10110
[6,4,5,3,2,1] => 11110
[6,5,1,2,3,4] => 10001
[6,5,1,2,4,3] => 10101
[6,5,1,3,2,4] => 11001
[6,5,1,3,4,2] => 11001
[6,5,1,4,2,3] => 11001
[6,5,1,4,3,2] => 11101
[6,5,2,1,3,4] => 11001
[6,5,2,1,4,3] => 11101
[6,5,2,3,1,4] => 11001
[6,5,2,3,4,1] => 11001
[6,5,2,4,1,3] => 11001
[6,5,2,4,3,1] => 11101
[6,5,3,1,2,4] => 10101
[6,5,3,1,4,2] => 11101
[6,5,3,2,1,4] => 11101
[6,5,3,2,4,1] => 11101
[6,5,3,4,1,2] => 10101
[6,5,3,4,2,1] => 11101
[6,5,4,1,2,3] => 10011
[6,5,4,1,3,2] => 11011
[6,5,4,2,1,3] => 11011
[6,5,4,2,3,1] => 11011
[6,5,4,3,1,2] => 10111
[6,5,4,3,2,1] => 11111
[1,2,3,4,5,6,7] => 000000
[1,2,3,4,5,7,6] => 000001
[1,2,3,4,6,5,7] => 000010
[1,2,3,4,6,7,5] => 000010
[1,2,3,4,7,5,6] => 000010
[1,2,3,4,7,6,5] => 000011
[1,2,3,5,4,6,7] => 000100
[1,2,3,5,4,7,6] => 000101
[1,2,3,5,6,4,7] => 000100
[1,2,3,5,6,7,4] => 000100
[1,2,3,5,7,4,6] => 000100
[1,2,3,5,7,6,4] => 000101
[1,2,3,6,4,5,7] => 000100
[1,2,3,6,4,7,5] => 000110
[1,2,3,6,5,4,7] => 000110
[1,2,3,6,5,7,4] => 000110
[1,2,3,6,7,4,5] => 000100
[1,2,3,6,7,5,4] => 000110
[1,2,3,7,4,5,6] => 000100
[1,2,3,7,4,6,5] => 000110
[1,2,3,7,5,4,6] => 000110
[1,2,3,7,5,6,4] => 000110
[1,2,3,7,6,4,5] => 000101
[1,2,3,7,6,5,4] => 000111
[1,2,4,3,5,6,7] => 001000
[1,2,4,3,5,7,6] => 001001
[1,2,4,3,6,5,7] => 001010
[1,2,4,3,6,7,5] => 001010
[1,2,4,3,7,5,6] => 001010
[1,2,4,3,7,6,5] => 001011
[1,2,4,5,3,6,7] => 001000
[1,2,4,5,3,7,6] => 001001
[1,2,4,5,6,3,7] => 001000
[1,2,4,5,6,7,3] => 001000
[1,2,4,5,7,3,6] => 001000
[1,2,4,5,7,6,3] => 001001
[1,2,4,6,3,5,7] => 001000
[1,2,4,6,3,7,5] => 001010
[1,2,4,6,5,3,7] => 001010
[1,2,4,6,5,7,3] => 001010
[1,2,4,6,7,3,5] => 001000
[1,2,4,6,7,5,3] => 001010
[1,2,4,7,3,5,6] => 001000
[1,2,4,7,3,6,5] => 001010
[1,2,4,7,5,3,6] => 001010
[1,2,4,7,5,6,3] => 001010
[1,2,4,7,6,3,5] => 001001
[1,2,4,7,6,5,3] => 001011
[1,2,5,3,4,6,7] => 001000
[1,2,5,3,4,7,6] => 001001
[1,2,5,3,6,4,7] => 001100
[1,2,5,3,6,7,4] => 001100
[1,2,5,3,7,4,6] => 001100
[1,2,5,3,7,6,4] => 001101
[1,2,5,4,3,6,7] => 001100
[1,2,5,4,3,7,6] => 001101
[1,2,5,4,6,3,7] => 001100
[1,2,5,4,6,7,3] => 001100
[1,2,5,4,7,3,6] => 001100
[1,2,5,4,7,6,3] => 001101
[1,2,5,6,3,4,7] => 001000
[1,2,5,6,3,7,4] => 001100
[1,2,5,6,4,3,7] => 001100
[1,2,5,6,4,7,3] => 001100
[1,2,5,6,7,3,4] => 001000
[1,2,5,6,7,4,3] => 001100
[1,2,5,7,3,4,6] => 001000
[1,2,5,7,3,6,4] => 001100
[1,2,5,7,4,3,6] => 001100
[1,2,5,7,4,6,3] => 001100
[1,2,5,7,6,3,4] => 001001
[1,2,5,7,6,4,3] => 001101
[1,2,6,3,4,5,7] => 001000
[1,2,6,3,4,7,5] => 001010
[1,2,6,3,5,4,7] => 001100
[1,2,6,3,5,7,4] => 001100
[1,2,6,3,7,4,5] => 001100
[1,2,6,3,7,5,4] => 001110
[1,2,6,4,3,5,7] => 001100
[1,2,6,4,3,7,5] => 001110
[1,2,6,4,5,3,7] => 001100
[1,2,6,4,5,7,3] => 001100
[1,2,6,4,7,3,5] => 001100
[1,2,6,4,7,5,3] => 001110
[1,2,6,5,3,4,7] => 001010
[1,2,6,5,3,7,4] => 001110
[1,2,6,5,4,3,7] => 001110
[1,2,6,5,4,7,3] => 001110
[1,2,6,5,7,3,4] => 001010
[1,2,6,5,7,4,3] => 001110
[1,2,6,7,3,4,5] => 001000
[1,2,6,7,3,5,4] => 001100
[1,2,6,7,4,3,5] => 001100
[1,2,6,7,4,5,3] => 001100
[1,2,6,7,5,3,4] => 001010
[1,2,6,7,5,4,3] => 001110
[1,2,7,3,4,5,6] => 001000
[1,2,7,3,4,6,5] => 001010
[1,2,7,3,5,4,6] => 001100
[1,2,7,3,5,6,4] => 001100
[1,2,7,3,6,4,5] => 001100
[1,2,7,3,6,5,4] => 001110
[1,2,7,4,3,5,6] => 001100
[1,2,7,4,3,6,5] => 001110
[1,2,7,4,5,3,6] => 001100
[1,2,7,4,5,6,3] => 001100
[1,2,7,4,6,3,5] => 001100
[1,2,7,4,6,5,3] => 001110
[1,2,7,5,3,4,6] => 001010
[1,2,7,5,3,6,4] => 001110
[1,2,7,5,4,3,6] => 001110
[1,2,7,5,4,6,3] => 001110
[1,2,7,5,6,3,4] => 001010
[1,2,7,5,6,4,3] => 001110
[1,2,7,6,3,4,5] => 001001
[1,2,7,6,3,5,4] => 001101
[1,2,7,6,4,3,5] => 001101
[1,2,7,6,4,5,3] => 001101
[1,2,7,6,5,3,4] => 001011
[1,2,7,6,5,4,3] => 001111
[1,3,2,4,5,6,7] => 010000
[1,3,2,4,5,7,6] => 010001
[1,3,2,4,6,5,7] => 010010
[1,3,2,4,6,7,5] => 010010
[1,3,2,4,7,5,6] => 010010
[1,3,2,4,7,6,5] => 010011
[1,3,2,5,4,6,7] => 010100
[1,3,2,5,4,7,6] => 010101
[1,3,2,5,6,4,7] => 010100
[1,3,2,5,6,7,4] => 010100
[1,3,2,5,7,4,6] => 010100
[1,3,2,5,7,6,4] => 010101
[1,3,2,6,4,5,7] => 010100
[1,3,2,6,4,7,5] => 010110
[1,3,2,6,5,4,7] => 010110
[1,3,2,6,5,7,4] => 010110
[1,3,2,6,7,4,5] => 010100
[1,3,2,6,7,5,4] => 010110
[1,3,2,7,4,5,6] => 010100
[1,3,2,7,4,6,5] => 010110
[1,3,2,7,5,4,6] => 010110
[1,3,2,7,5,6,4] => 010110
[1,3,2,7,6,4,5] => 010101
[1,3,2,7,6,5,4] => 010111
[1,3,4,2,5,6,7] => 010000
[1,3,4,2,5,7,6] => 010001
[1,3,4,2,6,5,7] => 010010
[1,3,4,2,6,7,5] => 010010
[1,3,4,2,7,5,6] => 010010
[1,3,4,2,7,6,5] => 010011
[1,3,4,5,2,6,7] => 010000
[1,3,4,5,2,7,6] => 010001
[1,3,4,5,6,2,7] => 010000
[1,3,4,5,6,7,2] => 010000
[1,3,4,5,7,2,6] => 010000
[1,3,4,5,7,6,2] => 010001
[1,3,4,6,2,5,7] => 010000
[1,3,4,6,2,7,5] => 010010
[1,3,4,6,5,2,7] => 010010
[1,3,4,6,5,7,2] => 010010
[1,3,4,6,7,2,5] => 010000
[1,3,4,6,7,5,2] => 010010
[1,3,4,7,2,5,6] => 010000
[1,3,4,7,2,6,5] => 010010
[1,3,4,7,5,2,6] => 010010
[1,3,4,7,5,6,2] => 010010
[1,3,4,7,6,2,5] => 010001
[1,3,4,7,6,5,2] => 010011
[1,3,5,2,4,6,7] => 010000
[1,3,5,2,4,7,6] => 010001
[1,3,5,2,6,4,7] => 010100
[1,3,5,2,6,7,4] => 010100
[1,3,5,2,7,4,6] => 010100
[1,3,5,2,7,6,4] => 010101
[1,3,5,4,2,6,7] => 010100
[1,3,5,4,2,7,6] => 010101
[1,3,5,4,6,2,7] => 010100
[1,3,5,4,6,7,2] => 010100
[1,3,5,4,7,2,6] => 010100
[1,3,5,4,7,6,2] => 010101
[1,3,5,6,2,4,7] => 010000
[1,3,5,6,2,7,4] => 010100
[1,3,5,6,4,2,7] => 010100
[1,3,5,6,4,7,2] => 010100
[1,3,5,6,7,2,4] => 010000
[1,3,5,6,7,4,2] => 010100
[1,3,5,7,2,4,6] => 010000
[1,3,5,7,2,6,4] => 010100
[1,3,5,7,4,2,6] => 010100
[1,3,5,7,4,6,2] => 010100
[1,3,5,7,6,2,4] => 010001
[1,3,5,7,6,4,2] => 010101
[1,3,6,2,4,5,7] => 010000
[1,3,6,2,4,7,5] => 010010
[1,3,6,2,5,4,7] => 010100
[1,3,6,2,5,7,4] => 010100
[1,3,6,2,7,4,5] => 010100
[1,3,6,2,7,5,4] => 010110
[1,3,6,4,2,5,7] => 010100
[1,3,6,4,2,7,5] => 010110
[1,3,6,4,5,2,7] => 010100
[1,3,6,4,5,7,2] => 010100
[1,3,6,4,7,2,5] => 010100
[1,3,6,4,7,5,2] => 010110
[1,3,6,5,2,4,7] => 010010
[1,3,6,5,2,7,4] => 010110
[1,3,6,5,4,2,7] => 010110
[1,3,6,5,4,7,2] => 010110
[1,3,6,5,7,2,4] => 010010
[1,3,6,5,7,4,2] => 010110
[1,3,6,7,2,4,5] => 010000
[1,3,6,7,2,5,4] => 010100
[1,3,6,7,4,2,5] => 010100
[1,3,6,7,4,5,2] => 010100
[1,3,6,7,5,2,4] => 010010
[1,3,6,7,5,4,2] => 010110
[1,3,7,2,4,5,6] => 010000
[1,3,7,2,4,6,5] => 010010
[1,3,7,2,5,4,6] => 010100
[1,3,7,2,5,6,4] => 010100
[1,3,7,2,6,4,5] => 010100
[1,3,7,2,6,5,4] => 010110
[1,3,7,4,2,5,6] => 010100
[1,3,7,4,2,6,5] => 010110
[1,3,7,4,5,2,6] => 010100
[1,3,7,4,5,6,2] => 010100
[1,3,7,4,6,2,5] => 010100
[1,3,7,4,6,5,2] => 010110
[1,3,7,5,2,4,6] => 010010
[1,3,7,5,2,6,4] => 010110
[1,3,7,5,4,2,6] => 010110
[1,3,7,5,4,6,2] => 010110
[1,3,7,5,6,2,4] => 010010
[1,3,7,5,6,4,2] => 010110
[1,3,7,6,2,4,5] => 010001
[1,3,7,6,2,5,4] => 010101
[1,3,7,6,4,2,5] => 010101
[1,3,7,6,4,5,2] => 010101
[1,3,7,6,5,2,4] => 010011
[1,3,7,6,5,4,2] => 010111
[1,4,2,3,5,6,7] => 010000
[1,4,2,3,5,7,6] => 010001
[1,4,2,3,6,5,7] => 010010
[1,4,2,3,6,7,5] => 010010
[1,4,2,3,7,5,6] => 010010
[1,4,2,3,7,6,5] => 010011
[1,4,2,5,3,6,7] => 011000
[1,4,2,5,3,7,6] => 011001
[1,4,2,5,6,3,7] => 011000
[1,4,2,5,6,7,3] => 011000
[1,4,2,5,7,3,6] => 011000
[1,4,2,5,7,6,3] => 011001
[1,4,2,6,3,5,7] => 011000
[1,4,2,6,3,7,5] => 011010
[1,4,2,6,5,3,7] => 011010
[1,4,2,6,5,7,3] => 011010
[1,4,2,6,7,3,5] => 011000
[1,4,2,6,7,5,3] => 011010
[1,4,2,7,3,5,6] => 011000
[1,4,2,7,3,6,5] => 011010
[1,4,2,7,5,3,6] => 011010
[1,4,2,7,5,6,3] => 011010
[1,4,2,7,6,3,5] => 011001
[1,4,2,7,6,5,3] => 011011
[1,4,3,2,5,6,7] => 011000
[1,4,3,2,5,7,6] => 011001
[1,4,3,2,6,5,7] => 011010
[1,4,3,2,6,7,5] => 011010
[1,4,3,2,7,5,6] => 011010
[1,4,3,2,7,6,5] => 011011
[1,4,3,5,2,6,7] => 011000
[1,4,3,5,2,7,6] => 011001
[1,4,3,5,6,2,7] => 011000
[1,4,3,5,6,7,2] => 011000
[1,4,3,5,7,2,6] => 011000
[1,4,3,5,7,6,2] => 011001
[1,4,3,6,2,5,7] => 011000
[1,4,3,6,2,7,5] => 011010
[1,4,3,6,5,2,7] => 011010
[1,4,3,6,5,7,2] => 011010
[1,4,3,6,7,2,5] => 011000
[1,4,3,6,7,5,2] => 011010
[1,4,3,7,2,5,6] => 011000
[1,4,3,7,2,6,5] => 011010
[1,4,3,7,5,2,6] => 011010
[1,4,3,7,5,6,2] => 011010
[1,4,3,7,6,2,5] => 011001
[1,4,3,7,6,5,2] => 011011
[1,4,5,2,3,6,7] => 010000
[1,4,5,2,3,7,6] => 010001
[1,4,5,2,6,3,7] => 011000
[1,4,5,2,6,7,3] => 011000
[1,4,5,2,7,3,6] => 011000
[1,4,5,2,7,6,3] => 011001
[1,4,5,3,2,6,7] => 011000
[1,4,5,3,2,7,6] => 011001
[1,4,5,3,6,2,7] => 011000
[1,4,5,3,6,7,2] => 011000
[1,4,5,3,7,2,6] => 011000
[1,4,5,3,7,6,2] => 011001
[1,4,5,6,2,3,7] => 010000
[1,4,5,6,2,7,3] => 011000
[1,4,5,6,3,2,7] => 011000
[1,4,5,6,3,7,2] => 011000
[1,4,5,6,7,2,3] => 010000
[1,4,5,6,7,3,2] => 011000
[1,4,5,7,2,3,6] => 010000
[1,4,5,7,2,6,3] => 011000
[1,4,5,7,3,2,6] => 011000
[1,4,5,7,3,6,2] => 011000
[1,4,5,7,6,2,3] => 010001
[1,4,5,7,6,3,2] => 011001
[1,4,6,2,3,5,7] => 010000
[1,4,6,2,3,7,5] => 010010
[1,4,6,2,5,3,7] => 011000
[1,4,6,2,5,7,3] => 011000
[1,4,6,2,7,3,5] => 011000
[1,4,6,2,7,5,3] => 011010
[1,4,6,3,2,5,7] => 011000
[1,4,6,3,2,7,5] => 011010
[1,4,6,3,5,2,7] => 011000
[1,4,6,3,5,7,2] => 011000
[1,4,6,3,7,2,5] => 011000
[1,4,6,3,7,5,2] => 011010
[1,4,6,5,2,3,7] => 010010
[1,4,6,5,2,7,3] => 011010
[1,4,6,5,3,2,7] => 011010
[1,4,6,5,3,7,2] => 011010
[1,4,6,5,7,2,3] => 010010
[1,4,6,5,7,3,2] => 011010
[1,4,6,7,2,3,5] => 010000
[1,4,6,7,2,5,3] => 011000
[1,4,6,7,3,2,5] => 011000
[1,4,6,7,3,5,2] => 011000
[1,4,6,7,5,2,3] => 010010
[1,4,6,7,5,3,2] => 011010
[1,4,7,2,3,5,6] => 010000
[1,4,7,2,3,6,5] => 010010
[1,4,7,2,5,3,6] => 011000
[1,4,7,2,5,6,3] => 011000
[1,4,7,2,6,3,5] => 011000
[1,4,7,2,6,5,3] => 011010
[1,4,7,3,2,5,6] => 011000
[1,4,7,3,2,6,5] => 011010
[1,4,7,3,5,2,6] => 011000
[1,4,7,3,5,6,2] => 011000
[1,4,7,3,6,2,5] => 011000
[1,4,7,3,6,5,2] => 011010
[1,4,7,5,2,3,6] => 010010
[1,4,7,5,2,6,3] => 011010
[1,4,7,5,3,2,6] => 011010
[1,4,7,5,3,6,2] => 011010
[1,4,7,5,6,2,3] => 010010
[1,4,7,5,6,3,2] => 011010
[1,4,7,6,2,3,5] => 010001
[1,4,7,6,2,5,3] => 011001
[1,4,7,6,3,2,5] => 011001
[1,4,7,6,3,5,2] => 011001
[1,4,7,6,5,2,3] => 010011
[1,4,7,6,5,3,2] => 011011
[1,5,2,3,4,6,7] => 010000
[1,5,2,3,4,7,6] => 010001
[1,5,2,3,6,4,7] => 010100
[1,5,2,3,6,7,4] => 010100
[1,5,2,3,7,4,6] => 010100
[1,5,2,3,7,6,4] => 010101
[1,5,2,4,3,6,7] => 011000
[1,5,2,4,3,7,6] => 011001
[1,5,2,4,6,3,7] => 011000
[1,5,2,4,6,7,3] => 011000
[1,5,2,4,7,3,6] => 011000
[1,5,2,4,7,6,3] => 011001
[1,5,2,6,3,4,7] => 011000
[1,5,2,6,3,7,4] => 011100
[1,5,2,6,4,3,7] => 011100
[1,5,2,6,4,7,3] => 011100
[1,5,2,6,7,3,4] => 011000
[1,5,2,6,7,4,3] => 011100
[1,5,2,7,3,4,6] => 011000
[1,5,2,7,3,6,4] => 011100
[1,5,2,7,4,3,6] => 011100
[1,5,2,7,4,6,3] => 011100
[1,5,2,7,6,3,4] => 011001
[1,5,2,7,6,4,3] => 011101
[1,5,3,2,4,6,7] => 011000
[1,5,3,2,4,7,6] => 011001
[1,5,3,2,6,4,7] => 011100
[1,5,3,2,6,7,4] => 011100
[1,5,3,2,7,4,6] => 011100
[1,5,3,2,7,6,4] => 011101
[1,5,3,4,2,6,7] => 011000
[1,5,3,4,2,7,6] => 011001
[1,5,3,4,6,2,7] => 011000
[1,5,3,4,6,7,2] => 011000
[1,5,3,4,7,2,6] => 011000
[1,5,3,4,7,6,2] => 011001
[1,5,3,6,2,4,7] => 011000
[1,5,3,6,2,7,4] => 011100
[1,5,3,6,4,2,7] => 011100
[1,5,3,6,4,7,2] => 011100
[1,5,3,6,7,2,4] => 011000
[1,5,3,6,7,4,2] => 011100
[1,5,3,7,2,4,6] => 011000
[1,5,3,7,2,6,4] => 011100
[1,5,3,7,4,2,6] => 011100
[1,5,3,7,4,6,2] => 011100
[1,5,3,7,6,2,4] => 011001
[1,5,3,7,6,4,2] => 011101
[1,5,4,2,3,6,7] => 010100
[1,5,4,2,3,7,6] => 010101
[1,5,4,2,6,3,7] => 011100
[1,5,4,2,6,7,3] => 011100
[1,5,4,2,7,3,6] => 011100
[1,5,4,2,7,6,3] => 011101
[1,5,4,3,2,6,7] => 011100
[1,5,4,3,2,7,6] => 011101
[1,5,4,3,6,2,7] => 011100
[1,5,4,3,6,7,2] => 011100
[1,5,4,3,7,2,6] => 011100
[1,5,4,3,7,6,2] => 011101
[1,5,4,6,2,3,7] => 010100
[1,5,4,6,2,7,3] => 011100
[1,5,4,6,3,2,7] => 011100
[1,5,4,6,3,7,2] => 011100
[1,5,4,6,7,2,3] => 010100
[1,5,4,6,7,3,2] => 011100
[1,5,4,7,2,3,6] => 010100
[1,5,4,7,2,6,3] => 011100
[1,5,4,7,3,2,6] => 011100
[1,5,4,7,3,6,2] => 011100
[1,5,4,7,6,2,3] => 010101
[1,5,4,7,6,3,2] => 011101
[1,5,6,2,3,4,7] => 010000
[1,5,6,2,3,7,4] => 010100
[1,5,6,2,4,3,7] => 011000
[1,5,6,2,4,7,3] => 011000
[1,5,6,2,7,3,4] => 011000
[1,5,6,2,7,4,3] => 011100
[1,5,6,3,2,4,7] => 011000
[1,5,6,3,2,7,4] => 011100
[1,5,6,3,4,2,7] => 011000
[1,5,6,3,4,7,2] => 011000
[1,5,6,3,7,2,4] => 011000
[1,5,6,3,7,4,2] => 011100
[1,5,6,4,2,3,7] => 010100
[1,5,6,4,2,7,3] => 011100
[1,5,6,4,3,2,7] => 011100
[1,5,6,4,3,7,2] => 011100
[1,5,6,4,7,2,3] => 010100
[1,5,6,4,7,3,2] => 011100
[1,5,6,7,2,3,4] => 010000
[1,5,6,7,2,4,3] => 011000
[1,5,6,7,3,2,4] => 011000
[1,5,6,7,3,4,2] => 011000
[1,5,6,7,4,2,3] => 010100
[1,5,6,7,4,3,2] => 011100
[1,5,7,2,3,4,6] => 010000
[1,5,7,2,3,6,4] => 010100
[1,5,7,2,4,3,6] => 011000
[1,5,7,2,4,6,3] => 011000
[1,5,7,2,6,3,4] => 011000
[1,5,7,2,6,4,3] => 011100
[1,5,7,3,2,4,6] => 011000
[1,5,7,3,2,6,4] => 011100
[1,5,7,3,4,2,6] => 011000
[1,5,7,3,4,6,2] => 011000
[1,5,7,3,6,2,4] => 011000
[1,5,7,3,6,4,2] => 011100
[1,5,7,4,2,3,6] => 010100
[1,5,7,4,2,6,3] => 011100
[1,5,7,4,3,2,6] => 011100
[1,5,7,4,3,6,2] => 011100
[1,5,7,4,6,2,3] => 010100
[1,5,7,4,6,3,2] => 011100
[1,5,7,6,2,3,4] => 010001
[1,5,7,6,2,4,3] => 011001
[1,5,7,6,3,2,4] => 011001
[1,5,7,6,3,4,2] => 011001
[1,5,7,6,4,2,3] => 010101
[1,5,7,6,4,3,2] => 011101
[1,6,2,3,4,5,7] => 010000
[1,6,2,3,4,7,5] => 010010
[1,6,2,3,5,4,7] => 010100
[1,6,2,3,5,7,4] => 010100
[1,6,2,3,7,4,5] => 010100
[1,6,2,3,7,5,4] => 010110
[1,6,2,4,3,5,7] => 011000
[1,6,2,4,3,7,5] => 011010
[1,6,2,4,5,3,7] => 011000
[1,6,2,4,5,7,3] => 011000
[1,6,2,4,7,3,5] => 011000
[1,6,2,4,7,5,3] => 011010
[1,6,2,5,3,4,7] => 011000
[1,6,2,5,3,7,4] => 011100
[1,6,2,5,4,3,7] => 011100
[1,6,2,5,4,7,3] => 011100
[1,6,2,5,7,3,4] => 011000
[1,6,2,5,7,4,3] => 011100
[1,6,2,7,3,4,5] => 011000
[1,6,2,7,3,5,4] => 011100
[1,6,2,7,4,3,5] => 011100
[1,6,2,7,4,5,3] => 011100
[1,6,2,7,5,3,4] => 011010
[1,6,2,7,5,4,3] => 011110
[1,6,3,2,4,5,7] => 011000
[1,6,3,2,4,7,5] => 011010
[1,6,3,2,5,4,7] => 011100
[1,6,3,2,5,7,4] => 011100
[1,6,3,2,7,4,5] => 011100
[1,6,3,2,7,5,4] => 011110
[1,6,3,4,2,5,7] => 011000
[1,6,3,4,2,7,5] => 011010
[1,6,3,4,5,2,7] => 011000
[1,6,3,4,5,7,2] => 011000
[1,6,3,4,7,2,5] => 011000
[1,6,3,4,7,5,2] => 011010
[1,6,3,5,2,4,7] => 011000
[1,6,3,5,2,7,4] => 011100
[1,6,3,5,4,2,7] => 011100
[1,6,3,5,4,7,2] => 011100
[1,6,3,5,7,2,4] => 011000
[1,6,3,5,7,4,2] => 011100
[1,6,3,7,2,4,5] => 011000
[1,6,3,7,2,5,4] => 011100
[1,6,3,7,4,2,5] => 011100
[1,6,3,7,4,5,2] => 011100
[1,6,3,7,5,2,4] => 011010
[1,6,3,7,5,4,2] => 011110
[1,6,4,2,3,5,7] => 010100
[1,6,4,2,3,7,5] => 010110
[1,6,4,2,5,3,7] => 011100
[1,6,4,2,5,7,3] => 011100
[1,6,4,2,7,3,5] => 011100
[1,6,4,2,7,5,3] => 011110
[1,6,4,3,2,5,7] => 011100
[1,6,4,3,2,7,5] => 011110
[1,6,4,3,5,2,7] => 011100
[1,6,4,3,5,7,2] => 011100
[1,6,4,3,7,2,5] => 011100
[1,6,4,3,7,5,2] => 011110
[1,6,4,5,2,3,7] => 010100
[1,6,4,5,2,7,3] => 011100
[1,6,4,5,3,2,7] => 011100
[1,6,4,5,3,7,2] => 011100
[1,6,4,5,7,2,3] => 010100
[1,6,4,5,7,3,2] => 011100
[1,6,4,7,2,3,5] => 010100
[1,6,4,7,2,5,3] => 011100
[1,6,4,7,3,2,5] => 011100
[1,6,4,7,3,5,2] => 011100
[1,6,4,7,5,2,3] => 010110
[1,6,4,7,5,3,2] => 011110
[1,6,5,2,3,4,7] => 010010
[1,6,5,2,3,7,4] => 010110
[1,6,5,2,4,3,7] => 011010
[1,6,5,2,4,7,3] => 011010
[1,6,5,2,7,3,4] => 011010
[1,6,5,2,7,4,3] => 011110
[1,6,5,3,2,4,7] => 011010
[1,6,5,3,2,7,4] => 011110
[1,6,5,3,4,2,7] => 011010
[1,6,5,3,4,7,2] => 011010
[1,6,5,3,7,2,4] => 011010
[1,6,5,3,7,4,2] => 011110
[1,6,5,4,2,3,7] => 010110
[1,6,5,4,2,7,3] => 011110
[1,6,5,4,3,2,7] => 011110
[1,6,5,4,3,7,2] => 011110
[1,6,5,4,7,2,3] => 010110
[1,6,5,4,7,3,2] => 011110
[1,6,5,7,2,3,4] => 010010
[1,6,5,7,2,4,3] => 011010
[1,6,5,7,3,2,4] => 011010
[1,6,5,7,3,4,2] => 011010
[1,6,5,7,4,2,3] => 010110
[1,6,5,7,4,3,2] => 011110
[1,6,7,2,3,4,5] => 010000
[1,6,7,2,3,5,4] => 010100
[1,6,7,2,4,3,5] => 011000
[1,6,7,2,4,5,3] => 011000
[1,6,7,2,5,3,4] => 011000
[1,6,7,2,5,4,3] => 011100
[1,6,7,3,2,4,5] => 011000
[1,6,7,3,2,5,4] => 011100
[1,6,7,3,4,2,5] => 011000
[1,6,7,3,4,5,2] => 011000
[1,6,7,3,5,2,4] => 011000
[1,6,7,3,5,4,2] => 011100
[1,6,7,4,2,3,5] => 010100
[1,6,7,4,2,5,3] => 011100
[1,6,7,4,3,2,5] => 011100
[1,6,7,4,3,5,2] => 011100
[1,6,7,4,5,2,3] => 010100
[1,6,7,4,5,3,2] => 011100
[1,6,7,5,2,3,4] => 010010
[1,6,7,5,2,4,3] => 011010
[1,6,7,5,3,2,4] => 011010
[1,6,7,5,3,4,2] => 011010
[1,6,7,5,4,2,3] => 010110
[1,6,7,5,4,3,2] => 011110
[1,7,2,3,4,5,6] => 010000
[1,7,2,3,4,6,5] => 010010
[1,7,2,3,5,4,6] => 010100
[1,7,2,3,5,6,4] => 010100
[1,7,2,3,6,4,5] => 010100
[1,7,2,3,6,5,4] => 010110
[1,7,2,4,3,5,6] => 011000
[1,7,2,4,3,6,5] => 011010
[1,7,2,4,5,3,6] => 011000
[1,7,2,4,5,6,3] => 011000
[1,7,2,4,6,3,5] => 011000
[1,7,2,4,6,5,3] => 011010
[1,7,2,5,3,4,6] => 011000
[1,7,2,5,3,6,4] => 011100
[1,7,2,5,4,3,6] => 011100
[1,7,2,5,4,6,3] => 011100
[1,7,2,5,6,3,4] => 011000
[1,7,2,5,6,4,3] => 011100
[1,7,2,6,3,4,5] => 011000
[1,7,2,6,3,5,4] => 011100
[1,7,2,6,4,3,5] => 011100
[1,7,2,6,4,5,3] => 011100
[1,7,2,6,5,3,4] => 011010
[1,7,2,6,5,4,3] => 011110
[1,7,3,2,4,5,6] => 011000
[1,7,3,2,4,6,5] => 011010
[1,7,3,2,5,4,6] => 011100
[1,7,3,2,5,6,4] => 011100
[1,7,3,2,6,4,5] => 011100
[1,7,3,2,6,5,4] => 011110
[1,7,3,4,2,5,6] => 011000
[1,7,3,4,2,6,5] => 011010
[1,7,3,4,5,2,6] => 011000
[1,7,3,4,5,6,2] => 011000
[1,7,3,4,6,2,5] => 011000
[1,7,3,4,6,5,2] => 011010
[1,7,3,5,2,4,6] => 011000
[1,7,3,5,2,6,4] => 011100
[1,7,3,5,4,2,6] => 011100
[1,7,3,5,4,6,2] => 011100
[1,7,3,5,6,2,4] => 011000
[1,7,3,5,6,4,2] => 011100
[1,7,3,6,2,4,5] => 011000
[1,7,3,6,2,5,4] => 011100
[1,7,3,6,4,2,5] => 011100
[1,7,3,6,4,5,2] => 011100
[1,7,3,6,5,2,4] => 011010
[1,7,3,6,5,4,2] => 011110
[1,7,4,2,3,5,6] => 010100
[1,7,4,2,3,6,5] => 010110
[1,7,4,2,5,3,6] => 011100
[1,7,4,2,5,6,3] => 011100
[1,7,4,2,6,3,5] => 011100
[1,7,4,2,6,5,3] => 011110
[1,7,4,3,2,5,6] => 011100
[1,7,4,3,2,6,5] => 011110
[1,7,4,3,5,2,6] => 011100
[1,7,4,3,5,6,2] => 011100
[1,7,4,3,6,2,5] => 011100
[1,7,4,3,6,5,2] => 011110
[1,7,4,5,2,3,6] => 010100
[1,7,4,5,2,6,3] => 011100
[1,7,4,5,3,2,6] => 011100
[1,7,4,5,3,6,2] => 011100
[1,7,4,5,6,2,3] => 010100
[1,7,4,5,6,3,2] => 011100
[1,7,4,6,2,3,5] => 010100
[1,7,4,6,2,5,3] => 011100
[1,7,4,6,3,2,5] => 011100
[1,7,4,6,3,5,2] => 011100
[1,7,4,6,5,2,3] => 010110
[1,7,4,6,5,3,2] => 011110
[1,7,5,2,3,4,6] => 010010
[1,7,5,2,3,6,4] => 010110
[1,7,5,2,4,3,6] => 011010
[1,7,5,2,4,6,3] => 011010
[1,7,5,2,6,3,4] => 011010
[1,7,5,2,6,4,3] => 011110
[1,7,5,3,2,4,6] => 011010
[1,7,5,3,2,6,4] => 011110
[1,7,5,3,4,2,6] => 011010
[1,7,5,3,4,6,2] => 011010
[1,7,5,3,6,2,4] => 011010
[1,7,5,3,6,4,2] => 011110
[1,7,5,4,2,3,6] => 010110
[1,7,5,4,2,6,3] => 011110
[1,7,5,4,3,2,6] => 011110
[1,7,5,4,3,6,2] => 011110
[1,7,5,4,6,2,3] => 010110
[1,7,5,4,6,3,2] => 011110
[1,7,5,6,2,3,4] => 010010
[1,7,5,6,2,4,3] => 011010
[1,7,5,6,3,2,4] => 011010
[1,7,5,6,3,4,2] => 011010
[1,7,5,6,4,2,3] => 010110
[1,7,5,6,4,3,2] => 011110
[1,7,6,2,3,4,5] => 010001
[1,7,6,2,3,5,4] => 010101
[1,7,6,2,4,3,5] => 011001
[1,7,6,2,4,5,3] => 011001
[1,7,6,2,5,3,4] => 011001
[1,7,6,2,5,4,3] => 011101
[1,7,6,3,2,4,5] => 011001
[1,7,6,3,2,5,4] => 011101
[1,7,6,3,4,2,5] => 011001
[1,7,6,3,4,5,2] => 011001
[1,7,6,3,5,2,4] => 011001
[1,7,6,3,5,4,2] => 011101
[1,7,6,4,2,3,5] => 010101
[1,7,6,4,2,5,3] => 011101
[1,7,6,4,3,2,5] => 011101
[1,7,6,4,3,5,2] => 011101
[1,7,6,4,5,2,3] => 010101
[1,7,6,4,5,3,2] => 011101
[1,7,6,5,2,3,4] => 010011
[1,7,6,5,2,4,3] => 011011
[1,7,6,5,3,2,4] => 011011
[1,7,6,5,3,4,2] => 011011
[1,7,6,5,4,2,3] => 010111
[1,7,6,5,4,3,2] => 011111
[2,1,3,4,5,6,7] => 100000
[2,1,3,4,5,7,6] => 100001
[2,1,3,4,6,5,7] => 100010
[2,1,3,4,6,7,5] => 100010
[2,1,3,4,7,5,6] => 100010
[2,1,3,4,7,6,5] => 100011
[2,1,3,5,4,6,7] => 100100
[2,1,3,5,4,7,6] => 100101
[2,1,3,5,6,4,7] => 100100
[2,1,3,5,6,7,4] => 100100
[2,1,3,5,7,4,6] => 100100
[2,1,3,5,7,6,4] => 100101
[2,1,3,6,4,5,7] => 100100
[2,1,3,6,4,7,5] => 100110
[2,1,3,6,5,4,7] => 100110
[2,1,3,6,5,7,4] => 100110
[2,1,3,6,7,4,5] => 100100
[2,1,3,6,7,5,4] => 100110
[2,1,3,7,4,5,6] => 100100
[2,1,3,7,4,6,5] => 100110
[2,1,3,7,5,4,6] => 100110
[2,1,3,7,5,6,4] => 100110
[2,1,3,7,6,4,5] => 100101
[2,1,3,7,6,5,4] => 100111
[2,1,4,3,5,6,7] => 101000
[2,1,4,3,5,7,6] => 101001
[2,1,4,3,6,5,7] => 101010
[2,1,4,3,6,7,5] => 101010
[2,1,4,3,7,5,6] => 101010
[2,1,4,3,7,6,5] => 101011
[2,1,4,5,3,6,7] => 101000
[2,1,4,5,3,7,6] => 101001
[2,1,4,5,6,3,7] => 101000
[2,1,4,5,6,7,3] => 101000
[2,1,4,5,7,3,6] => 101000
[2,1,4,5,7,6,3] => 101001
[2,1,4,6,3,5,7] => 101000
[2,1,4,6,3,7,5] => 101010
[2,1,4,6,5,3,7] => 101010
[2,1,4,6,5,7,3] => 101010
[2,1,4,6,7,3,5] => 101000
[2,1,4,6,7,5,3] => 101010
[2,1,4,7,3,5,6] => 101000
[2,1,4,7,3,6,5] => 101010
[2,1,4,7,5,3,6] => 101010
[2,1,4,7,5,6,3] => 101010
[2,1,4,7,6,3,5] => 101001
[2,1,4,7,6,5,3] => 101011
[2,1,5,3,4,6,7] => 101000
[2,1,5,3,4,7,6] => 101001
[2,1,5,3,6,4,7] => 101100
[2,1,5,3,6,7,4] => 101100
[2,1,5,3,7,4,6] => 101100
[2,1,5,3,7,6,4] => 101101
[2,1,5,4,3,6,7] => 101100
[2,1,5,4,3,7,6] => 101101
[2,1,5,4,6,3,7] => 101100
[2,1,5,4,6,7,3] => 101100
[2,1,5,4,7,3,6] => 101100
[2,1,5,4,7,6,3] => 101101
[2,1,5,6,3,4,7] => 101000
[2,1,5,6,3,7,4] => 101100
[2,1,5,6,4,3,7] => 101100
[2,1,5,6,4,7,3] => 101100
[2,1,5,6,7,3,4] => 101000
[2,1,5,6,7,4,3] => 101100
[2,1,5,7,3,4,6] => 101000
[2,1,5,7,3,6,4] => 101100
[2,1,5,7,4,3,6] => 101100
[2,1,5,7,4,6,3] => 101100
[2,1,5,7,6,3,4] => 101001
[2,1,5,7,6,4,3] => 101101
[2,1,6,3,4,5,7] => 101000
[2,1,6,3,4,7,5] => 101010
[2,1,6,3,5,4,7] => 101100
[2,1,6,3,5,7,4] => 101100
[2,1,6,3,7,4,5] => 101100
[2,1,6,3,7,5,4] => 101110
[2,1,6,4,3,5,7] => 101100
[2,1,6,4,3,7,5] => 101110
[2,1,6,4,5,3,7] => 101100
[2,1,6,4,5,7,3] => 101100
[2,1,6,4,7,3,5] => 101100
[2,1,6,4,7,5,3] => 101110
[2,1,6,5,3,4,7] => 101010
[2,1,6,5,3,7,4] => 101110
[2,1,6,5,4,3,7] => 101110
[2,1,6,5,4,7,3] => 101110
[2,1,6,5,7,3,4] => 101010
[2,1,6,5,7,4,3] => 101110
[2,1,6,7,3,4,5] => 101000
[2,1,6,7,3,5,4] => 101100
[2,1,6,7,4,3,5] => 101100
[2,1,6,7,4,5,3] => 101100
[2,1,6,7,5,3,4] => 101010
[2,1,6,7,5,4,3] => 101110
[2,1,7,3,4,5,6] => 101000
[2,1,7,3,4,6,5] => 101010
[2,1,7,3,5,4,6] => 101100
[2,1,7,3,5,6,4] => 101100
[2,1,7,3,6,4,5] => 101100
[2,1,7,3,6,5,4] => 101110
[2,1,7,4,3,5,6] => 101100
[2,1,7,4,3,6,5] => 101110
[2,1,7,4,5,3,6] => 101100
[2,1,7,4,5,6,3] => 101100
[2,1,7,4,6,3,5] => 101100
[2,1,7,4,6,5,3] => 101110
[2,1,7,5,3,4,6] => 101010
[2,1,7,5,3,6,4] => 101110
[2,1,7,5,4,3,6] => 101110
[2,1,7,5,4,6,3] => 101110
[2,1,7,5,6,3,4] => 101010
[2,1,7,5,6,4,3] => 101110
[2,1,7,6,3,4,5] => 101001
[2,1,7,6,3,5,4] => 101101
[2,1,7,6,4,3,5] => 101101
[2,1,7,6,4,5,3] => 101101
[2,1,7,6,5,3,4] => 101011
[2,1,7,6,5,4,3] => 101111
[2,3,1,4,5,6,7] => 100000
[2,3,1,4,5,7,6] => 100001
[2,3,1,4,6,5,7] => 100010
[2,3,1,4,6,7,5] => 100010
[2,3,1,4,7,5,6] => 100010
[2,3,1,4,7,6,5] => 100011
[2,3,1,5,4,6,7] => 100100
[2,3,1,5,4,7,6] => 100101
[2,3,1,5,6,4,7] => 100100
[2,3,1,5,6,7,4] => 100100
[2,3,1,5,7,4,6] => 100100
[2,3,1,5,7,6,4] => 100101
[2,3,1,6,4,5,7] => 100100
[2,3,1,6,4,7,5] => 100110
[2,3,1,6,5,4,7] => 100110
[2,3,1,6,5,7,4] => 100110
[2,3,1,6,7,4,5] => 100100
[2,3,1,6,7,5,4] => 100110
[2,3,1,7,4,5,6] => 100100
[2,3,1,7,4,6,5] => 100110
[2,3,1,7,5,4,6] => 100110
[2,3,1,7,5,6,4] => 100110
[2,3,1,7,6,4,5] => 100101
[2,3,1,7,6,5,4] => 100111
[2,3,4,1,5,6,7] => 100000
[2,3,4,1,5,7,6] => 100001
[2,3,4,1,6,5,7] => 100010
[2,3,4,1,6,7,5] => 100010
[2,3,4,1,7,5,6] => 100010
[2,3,4,1,7,6,5] => 100011
[2,3,4,5,1,6,7] => 100000
[2,3,4,5,1,7,6] => 100001
[2,3,4,5,6,1,7] => 100000
[2,3,4,5,6,7,1] => 100000
[2,3,4,5,7,1,6] => 100000
[2,3,4,5,7,6,1] => 100001
[2,3,4,6,1,5,7] => 100000
[2,3,4,6,1,7,5] => 100010
[2,3,4,6,5,1,7] => 100010
[2,3,4,6,5,7,1] => 100010
[2,3,4,6,7,1,5] => 100000
[2,3,4,6,7,5,1] => 100010
[2,3,4,7,1,5,6] => 100000
[2,3,4,7,1,6,5] => 100010
[2,3,4,7,5,1,6] => 100010
[2,3,4,7,5,6,1] => 100010
[2,3,4,7,6,1,5] => 100001
[2,3,4,7,6,5,1] => 100011
[2,3,5,1,4,6,7] => 100000
[2,3,5,1,4,7,6] => 100001
[2,3,5,1,6,4,7] => 100100
[2,3,5,1,6,7,4] => 100100
[2,3,5,1,7,4,6] => 100100
[2,3,5,1,7,6,4] => 100101
[2,3,5,4,1,6,7] => 100100
[2,3,5,4,1,7,6] => 100101
[2,3,5,4,6,1,7] => 100100
[2,3,5,4,6,7,1] => 100100
[2,3,5,4,7,1,6] => 100100
[2,3,5,4,7,6,1] => 100101
[2,3,5,6,1,4,7] => 100000
[2,3,5,6,1,7,4] => 100100
[2,3,5,6,4,1,7] => 100100
[2,3,5,6,4,7,1] => 100100
[2,3,5,6,7,1,4] => 100000
[2,3,5,6,7,4,1] => 100100
[2,3,5,7,1,4,6] => 100000
[2,3,5,7,1,6,4] => 100100
[2,3,5,7,4,1,6] => 100100
[2,3,5,7,4,6,1] => 100100
[2,3,5,7,6,1,4] => 100001
[2,3,5,7,6,4,1] => 100101
[2,3,6,1,4,5,7] => 100000
[2,3,6,1,4,7,5] => 100010
[2,3,6,1,5,4,7] => 100100
[2,3,6,1,5,7,4] => 100100
[2,3,6,1,7,4,5] => 100100
[2,3,6,1,7,5,4] => 100110
[2,3,6,4,1,5,7] => 100100
[2,3,6,4,1,7,5] => 100110
[2,3,6,4,5,1,7] => 100100
[2,3,6,4,5,7,1] => 100100
[2,3,6,4,7,1,5] => 100100
[2,3,6,4,7,5,1] => 100110
[2,3,6,5,1,4,7] => 100010
[2,3,6,5,1,7,4] => 100110
[2,3,6,5,4,1,7] => 100110
[2,3,6,5,4,7,1] => 100110
[2,3,6,5,7,1,4] => 100010
[2,3,6,5,7,4,1] => 100110
[2,3,6,7,1,4,5] => 100000
[2,3,6,7,1,5,4] => 100100
[2,3,6,7,4,1,5] => 100100
[2,3,6,7,4,5,1] => 100100
[2,3,6,7,5,1,4] => 100010
[2,3,6,7,5,4,1] => 100110
[2,3,7,1,4,5,6] => 100000
[2,3,7,1,4,6,5] => 100010
[2,3,7,1,5,4,6] => 100100
[2,3,7,1,5,6,4] => 100100
[2,3,7,1,6,4,5] => 100100
[2,3,7,1,6,5,4] => 100110
[2,3,7,4,1,5,6] => 100100
[2,3,7,4,1,6,5] => 100110
[2,3,7,4,5,1,6] => 100100
[2,3,7,4,5,6,1] => 100100
[2,3,7,4,6,1,5] => 100100
[2,3,7,4,6,5,1] => 100110
[2,3,7,5,1,4,6] => 100010
[2,3,7,5,1,6,4] => 100110
[2,3,7,5,4,1,6] => 100110
[2,3,7,5,4,6,1] => 100110
[2,3,7,5,6,1,4] => 100010
[2,3,7,5,6,4,1] => 100110
[2,3,7,6,1,4,5] => 100001
[2,3,7,6,1,5,4] => 100101
[2,3,7,6,4,1,5] => 100101
[2,3,7,6,4,5,1] => 100101
[2,3,7,6,5,1,4] => 100011
[2,3,7,6,5,4,1] => 100111
[2,4,1,3,5,6,7] => 100000
[2,4,1,3,5,7,6] => 100001
[2,4,1,3,6,5,7] => 100010
[2,4,1,3,6,7,5] => 100010
[2,4,1,3,7,5,6] => 100010
[2,4,1,3,7,6,5] => 100011
[2,4,1,5,3,6,7] => 101000
[2,4,1,5,3,7,6] => 101001
[2,4,1,5,6,3,7] => 101000
[2,4,1,5,6,7,3] => 101000
[2,4,1,5,7,3,6] => 101000
[2,4,1,5,7,6,3] => 101001
[2,4,1,6,3,5,7] => 101000
[2,4,1,6,3,7,5] => 101010
[2,4,1,6,5,3,7] => 101010
[2,4,1,6,5,7,3] => 101010
[2,4,1,6,7,3,5] => 101000
[2,4,1,6,7,5,3] => 101010
[2,4,1,7,3,5,6] => 101000
[2,4,1,7,3,6,5] => 101010
[2,4,1,7,5,3,6] => 101010
[2,4,1,7,5,6,3] => 101010
[2,4,1,7,6,3,5] => 101001
[2,4,1,7,6,5,3] => 101011
[2,4,3,1,5,6,7] => 101000
[2,4,3,1,5,7,6] => 101001
[2,4,3,1,6,5,7] => 101010
[2,4,3,1,6,7,5] => 101010
[2,4,3,1,7,5,6] => 101010
[2,4,3,1,7,6,5] => 101011
[2,4,3,5,1,6,7] => 101000
[2,4,3,5,1,7,6] => 101001
[2,4,3,5,6,1,7] => 101000
[2,4,3,5,6,7,1] => 101000
[2,4,3,5,7,1,6] => 101000
[2,4,3,5,7,6,1] => 101001
[2,4,3,6,1,5,7] => 101000
[2,4,3,6,1,7,5] => 101010
[2,4,3,6,5,1,7] => 101010
[2,4,3,6,5,7,1] => 101010
[2,4,3,6,7,1,5] => 101000
[2,4,3,6,7,5,1] => 101010
[2,4,3,7,1,5,6] => 101000
[2,4,3,7,1,6,5] => 101010
[2,4,3,7,5,1,6] => 101010
[2,4,3,7,5,6,1] => 101010
[2,4,3,7,6,1,5] => 101001
[2,4,3,7,6,5,1] => 101011
[2,4,5,1,3,6,7] => 100000
[2,4,5,1,3,7,6] => 100001
[2,4,5,1,6,3,7] => 101000
[2,4,5,1,6,7,3] => 101000
[2,4,5,1,7,3,6] => 101000
[2,4,5,1,7,6,3] => 101001
[2,4,5,3,1,6,7] => 101000
[2,4,5,3,1,7,6] => 101001
[2,4,5,3,6,1,7] => 101000
[2,4,5,3,6,7,1] => 101000
[2,4,5,3,7,1,6] => 101000
[2,4,5,3,7,6,1] => 101001
[2,4,5,6,1,3,7] => 100000
[2,4,5,6,1,7,3] => 101000
[2,4,5,6,3,1,7] => 101000
[2,4,5,6,3,7,1] => 101000
[2,4,5,6,7,1,3] => 100000
[2,4,5,6,7,3,1] => 101000
[2,4,5,7,1,3,6] => 100000
[2,4,5,7,1,6,3] => 101000
[2,4,5,7,3,1,6] => 101000
[2,4,5,7,3,6,1] => 101000
[2,4,5,7,6,1,3] => 100001
[2,4,5,7,6,3,1] => 101001
[2,4,6,1,3,5,7] => 100000
[2,4,6,1,3,7,5] => 100010
[2,4,6,1,5,3,7] => 101000
[2,4,6,1,5,7,3] => 101000
[2,4,6,1,7,3,5] => 101000
[2,4,6,1,7,5,3] => 101010
[2,4,6,3,1,5,7] => 101000
[2,4,6,3,1,7,5] => 101010
[2,4,6,3,5,1,7] => 101000
[2,4,6,3,5,7,1] => 101000
[2,4,6,3,7,1,5] => 101000
[2,4,6,3,7,5,1] => 101010
[2,4,6,5,1,3,7] => 100010
[2,4,6,5,1,7,3] => 101010
[2,4,6,5,3,1,7] => 101010
[2,4,6,5,3,7,1] => 101010
[2,4,6,5,7,1,3] => 100010
[2,4,6,5,7,3,1] => 101010
[2,4,6,7,1,3,5] => 100000
[2,4,6,7,1,5,3] => 101000
[2,4,6,7,3,1,5] => 101000
[2,4,6,7,3,5,1] => 101000
[2,4,6,7,5,1,3] => 100010
[2,4,6,7,5,3,1] => 101010
[2,4,7,1,3,5,6] => 100000
[2,4,7,1,3,6,5] => 100010
[2,4,7,1,5,3,6] => 101000
[2,4,7,1,5,6,3] => 101000
[2,4,7,1,6,3,5] => 101000
[2,4,7,1,6,5,3] => 101010
[2,4,7,3,1,5,6] => 101000
[2,4,7,3,1,6,5] => 101010
[2,4,7,3,5,1,6] => 101000
[2,4,7,3,5,6,1] => 101000
[2,4,7,3,6,1,5] => 101000
[2,4,7,3,6,5,1] => 101010
[2,4,7,5,1,3,6] => 100010
[2,4,7,5,1,6,3] => 101010
[2,4,7,5,3,1,6] => 101010
[2,4,7,5,3,6,1] => 101010
[2,4,7,5,6,1,3] => 100010
[2,4,7,5,6,3,1] => 101010
[2,4,7,6,1,3,5] => 100001
[2,4,7,6,1,5,3] => 101001
[2,4,7,6,3,1,5] => 101001
[2,4,7,6,3,5,1] => 101001
[2,4,7,6,5,1,3] => 100011
[2,4,7,6,5,3,1] => 101011
[2,5,1,3,4,6,7] => 100000
[2,5,1,3,4,7,6] => 100001
[2,5,1,3,6,4,7] => 100100
[2,5,1,3,6,7,4] => 100100
[2,5,1,3,7,4,6] => 100100
[2,5,1,3,7,6,4] => 100101
[2,5,1,4,3,6,7] => 101000
[2,5,1,4,3,7,6] => 101001
[2,5,1,4,6,3,7] => 101000
[2,5,1,4,6,7,3] => 101000
[2,5,1,4,7,3,6] => 101000
[2,5,1,4,7,6,3] => 101001
[2,5,1,6,3,4,7] => 101000
[2,5,1,6,3,7,4] => 101100
[2,5,1,6,4,3,7] => 101100
[2,5,1,6,4,7,3] => 101100
[2,5,1,6,7,3,4] => 101000
[2,5,1,6,7,4,3] => 101100
[2,5,1,7,3,4,6] => 101000
[2,5,1,7,3,6,4] => 101100
[2,5,1,7,4,3,6] => 101100
[2,5,1,7,4,6,3] => 101100
[2,5,1,7,6,3,4] => 101001
[2,5,1,7,6,4,3] => 101101
[2,5,3,1,4,6,7] => 101000
[2,5,3,1,4,7,6] => 101001
[2,5,3,1,6,4,7] => 101100
[2,5,3,1,6,7,4] => 101100
[2,5,3,1,7,4,6] => 101100
[2,5,3,1,7,6,4] => 101101
[2,5,3,4,1,6,7] => 101000
[2,5,3,4,1,7,6] => 101001
[2,5,3,4,6,1,7] => 101000
[2,5,3,4,6,7,1] => 101000
[2,5,3,4,7,1,6] => 101000
[2,5,3,4,7,6,1] => 101001
[2,5,3,6,1,4,7] => 101000
[2,5,3,6,1,7,4] => 101100
[2,5,3,6,4,1,7] => 101100
[2,5,3,6,4,7,1] => 101100
[2,5,3,6,7,1,4] => 101000
[2,5,3,6,7,4,1] => 101100
[2,5,3,7,1,4,6] => 101000
[2,5,3,7,1,6,4] => 101100
[2,5,3,7,4,1,6] => 101100
[2,5,3,7,4,6,1] => 101100
[2,5,3,7,6,1,4] => 101001
[2,5,3,7,6,4,1] => 101101
[2,5,4,1,3,6,7] => 100100
[2,5,4,1,3,7,6] => 100101
[2,5,4,1,6,3,7] => 101100
[2,5,4,1,6,7,3] => 101100
[2,5,4,1,7,3,6] => 101100
[2,5,4,1,7,6,3] => 101101
[2,5,4,3,1,6,7] => 101100
[2,5,4,3,1,7,6] => 101101
[2,5,4,3,6,1,7] => 101100
[2,5,4,3,6,7,1] => 101100
[2,5,4,3,7,1,6] => 101100
[2,5,4,3,7,6,1] => 101101
[2,5,4,6,1,3,7] => 100100
[2,5,4,6,1,7,3] => 101100
[2,5,4,6,3,1,7] => 101100
[2,5,4,6,3,7,1] => 101100
[2,5,4,6,7,1,3] => 100100
[2,5,4,6,7,3,1] => 101100
[2,5,4,7,1,3,6] => 100100
[2,5,4,7,1,6,3] => 101100
[2,5,4,7,3,1,6] => 101100
[2,5,4,7,3,6,1] => 101100
[2,5,4,7,6,1,3] => 100101
[2,5,4,7,6,3,1] => 101101
[2,5,6,1,3,4,7] => 100000
[2,5,6,1,3,7,4] => 100100
[2,5,6,1,4,3,7] => 101000
[2,5,6,1,4,7,3] => 101000
[2,5,6,1,7,3,4] => 101000
[2,5,6,1,7,4,3] => 101100
[2,5,6,3,1,4,7] => 101000
[2,5,6,3,1,7,4] => 101100
[2,5,6,3,4,1,7] => 101000
[2,5,6,3,4,7,1] => 101000
[2,5,6,3,7,1,4] => 101000
[2,5,6,3,7,4,1] => 101100
[2,5,6,4,1,3,7] => 100100
[2,5,6,4,1,7,3] => 101100
[2,5,6,4,3,1,7] => 101100
[2,5,6,4,3,7,1] => 101100
[2,5,6,4,7,1,3] => 100100
[2,5,6,4,7,3,1] => 101100
[2,5,6,7,1,3,4] => 100000
[2,5,6,7,1,4,3] => 101000
[2,5,6,7,3,1,4] => 101000
[2,5,6,7,3,4,1] => 101000
[2,5,6,7,4,1,3] => 100100
[2,5,6,7,4,3,1] => 101100
[2,5,7,1,3,4,6] => 100000
[2,5,7,1,3,6,4] => 100100
[2,5,7,1,4,3,6] => 101000
[2,5,7,1,4,6,3] => 101000
[2,5,7,1,6,3,4] => 101000
[2,5,7,1,6,4,3] => 101100
[2,5,7,3,1,4,6] => 101000
[2,5,7,3,1,6,4] => 101100
[2,5,7,3,4,1,6] => 101000
[2,5,7,3,4,6,1] => 101000
[2,5,7,3,6,1,4] => 101000
[2,5,7,3,6,4,1] => 101100
[2,5,7,4,1,3,6] => 100100
[2,5,7,4,1,6,3] => 101100
[2,5,7,4,3,1,6] => 101100
[2,5,7,4,3,6,1] => 101100
[2,5,7,4,6,1,3] => 100100
[2,5,7,4,6,3,1] => 101100
[2,5,7,6,1,3,4] => 100001
[2,5,7,6,1,4,3] => 101001
[2,5,7,6,3,1,4] => 101001
[2,5,7,6,3,4,1] => 101001
[2,5,7,6,4,1,3] => 100101
[2,5,7,6,4,3,1] => 101101
[2,6,1,3,4,5,7] => 100000
[2,6,1,3,4,7,5] => 100010
[2,6,1,3,5,4,7] => 100100
[2,6,1,3,5,7,4] => 100100
[2,6,1,3,7,4,5] => 100100
[2,6,1,3,7,5,4] => 100110
[2,6,1,4,3,5,7] => 101000
[2,6,1,4,3,7,5] => 101010
[2,6,1,4,5,3,7] => 101000
[2,6,1,4,5,7,3] => 101000
[2,6,1,4,7,3,5] => 101000
[2,6,1,4,7,5,3] => 101010
[2,6,1,5,3,4,7] => 101000
[2,6,1,5,3,7,4] => 101100
[2,6,1,5,4,3,7] => 101100
[2,6,1,5,4,7,3] => 101100
[2,6,1,5,7,3,4] => 101000
[2,6,1,5,7,4,3] => 101100
[2,6,1,7,3,4,5] => 101000
[2,6,1,7,3,5,4] => 101100
[2,6,1,7,4,3,5] => 101100
[2,6,1,7,4,5,3] => 101100
[2,6,1,7,5,3,4] => 101010
[2,6,1,7,5,4,3] => 101110
[2,6,3,1,4,5,7] => 101000
[2,6,3,1,4,7,5] => 101010
[2,6,3,1,5,4,7] => 101100
[2,6,3,1,5,7,4] => 101100
[2,6,3,1,7,4,5] => 101100
[2,6,3,1,7,5,4] => 101110
[2,6,3,4,1,5,7] => 101000
[2,6,3,4,1,7,5] => 101010
[2,6,3,4,5,1,7] => 101000
[2,6,3,4,5,7,1] => 101000
[2,6,3,4,7,1,5] => 101000
[2,6,3,4,7,5,1] => 101010
[2,6,3,5,1,4,7] => 101000
[2,6,3,5,1,7,4] => 101100
[2,6,3,5,4,1,7] => 101100
[2,6,3,5,4,7,1] => 101100
[2,6,3,5,7,1,4] => 101000
[2,6,3,5,7,4,1] => 101100
[2,6,3,7,1,4,5] => 101000
[2,6,3,7,1,5,4] => 101100
[2,6,3,7,4,1,5] => 101100
[2,6,3,7,4,5,1] => 101100
[2,6,3,7,5,1,4] => 101010
[2,6,3,7,5,4,1] => 101110
[2,6,4,1,3,5,7] => 100100
[2,6,4,1,3,7,5] => 100110
[2,6,4,1,5,3,7] => 101100
[2,6,4,1,5,7,3] => 101100
[2,6,4,1,7,3,5] => 101100
[2,6,4,1,7,5,3] => 101110
[2,6,4,3,1,5,7] => 101100
[2,6,4,3,1,7,5] => 101110
[2,6,4,3,5,1,7] => 101100
[2,6,4,3,5,7,1] => 101100
[2,6,4,3,7,1,5] => 101100
[2,6,4,3,7,5,1] => 101110
[2,6,4,5,1,3,7] => 100100
[2,6,4,5,1,7,3] => 101100
[2,6,4,5,3,1,7] => 101100
[2,6,4,5,3,7,1] => 101100
[2,6,4,5,7,1,3] => 100100
[2,6,4,5,7,3,1] => 101100
[2,6,4,7,1,3,5] => 100100
[2,6,4,7,1,5,3] => 101100
[2,6,4,7,3,1,5] => 101100
[2,6,4,7,3,5,1] => 101100
[2,6,4,7,5,1,3] => 100110
[2,6,4,7,5,3,1] => 101110
[2,6,5,1,3,4,7] => 100010
[2,6,5,1,3,7,4] => 100110
[2,6,5,1,4,3,7] => 101010
[2,6,5,1,4,7,3] => 101010
[2,6,5,1,7,3,4] => 101010
[2,6,5,1,7,4,3] => 101110
[2,6,5,3,1,4,7] => 101010
[2,6,5,3,1,7,4] => 101110
[2,6,5,3,4,1,7] => 101010
[2,6,5,3,4,7,1] => 101010
[2,6,5,3,7,1,4] => 101010
[2,6,5,3,7,4,1] => 101110
[2,6,5,4,1,3,7] => 100110
[2,6,5,4,1,7,3] => 101110
[2,6,5,4,3,1,7] => 101110
[2,6,5,4,3,7,1] => 101110
[2,6,5,4,7,1,3] => 100110
[2,6,5,4,7,3,1] => 101110
[2,6,5,7,1,3,4] => 100010
[2,6,5,7,1,4,3] => 101010
[2,6,5,7,3,1,4] => 101010
[2,6,5,7,3,4,1] => 101010
[2,6,5,7,4,1,3] => 100110
[2,6,5,7,4,3,1] => 101110
[2,6,7,1,3,4,5] => 100000
[2,6,7,1,3,5,4] => 100100
[2,6,7,1,4,3,5] => 101000
[2,6,7,1,4,5,3] => 101000
[2,6,7,1,5,3,4] => 101000
[2,6,7,1,5,4,3] => 101100
[2,6,7,3,1,4,5] => 101000
[2,6,7,3,1,5,4] => 101100
[2,6,7,3,4,1,5] => 101000
[2,6,7,3,4,5,1] => 101000
[2,6,7,3,5,1,4] => 101000
[2,6,7,3,5,4,1] => 101100
[2,6,7,4,1,3,5] => 100100
[2,6,7,4,1,5,3] => 101100
[2,6,7,4,3,1,5] => 101100
[2,6,7,4,3,5,1] => 101100
[2,6,7,4,5,1,3] => 100100
[2,6,7,4,5,3,1] => 101100
[2,6,7,5,1,3,4] => 100010
[2,6,7,5,1,4,3] => 101010
[2,6,7,5,3,1,4] => 101010
[2,6,7,5,3,4,1] => 101010
[2,6,7,5,4,1,3] => 100110
[2,6,7,5,4,3,1] => 101110
[2,7,1,3,4,5,6] => 100000
[2,7,1,3,4,6,5] => 100010
[2,7,1,3,5,4,6] => 100100
[2,7,1,3,5,6,4] => 100100
[2,7,1,3,6,4,5] => 100100
[2,7,1,3,6,5,4] => 100110
[2,7,1,4,3,5,6] => 101000
[2,7,1,4,3,6,5] => 101010
[2,7,1,4,5,3,6] => 101000
[2,7,1,4,5,6,3] => 101000
[2,7,1,4,6,3,5] => 101000
[2,7,1,4,6,5,3] => 101010
[2,7,1,5,3,4,6] => 101000
[2,7,1,5,3,6,4] => 101100
[2,7,1,5,4,3,6] => 101100
[2,7,1,5,4,6,3] => 101100
[2,7,1,5,6,3,4] => 101000
[2,7,1,5,6,4,3] => 101100
[2,7,1,6,3,4,5] => 101000
[2,7,1,6,3,5,4] => 101100
[2,7,1,6,4,3,5] => 101100
[2,7,1,6,4,5,3] => 101100
[2,7,1,6,5,3,4] => 101010
[2,7,1,6,5,4,3] => 101110
[2,7,3,1,4,5,6] => 101000
[2,7,3,1,4,6,5] => 101010
[2,7,3,1,5,4,6] => 101100
[2,7,3,1,5,6,4] => 101100
[2,7,3,1,6,4,5] => 101100
[2,7,3,1,6,5,4] => 101110
[2,7,3,4,1,5,6] => 101000
[2,7,3,4,1,6,5] => 101010
[2,7,3,4,5,1,6] => 101000
[2,7,3,4,5,6,1] => 101000
[2,7,3,4,6,1,5] => 101000
[2,7,3,4,6,5,1] => 101010
[2,7,3,5,1,4,6] => 101000
[2,7,3,5,1,6,4] => 101100
[2,7,3,5,4,1,6] => 101100
[2,7,3,5,4,6,1] => 101100
[2,7,3,5,6,1,4] => 101000
[2,7,3,5,6,4,1] => 101100
[2,7,3,6,1,4,5] => 101000
[2,7,3,6,1,5,4] => 101100
[2,7,3,6,4,1,5] => 101100
[2,7,3,6,4,5,1] => 101100
[2,7,3,6,5,1,4] => 101010
[2,7,3,6,5,4,1] => 101110
[2,7,4,1,3,5,6] => 100100
[2,7,4,1,3,6,5] => 100110
[2,7,4,1,5,3,6] => 101100
[2,7,4,1,5,6,3] => 101100
[2,7,4,1,6,3,5] => 101100
[2,7,4,1,6,5,3] => 101110
[2,7,4,3,1,5,6] => 101100
[2,7,4,3,1,6,5] => 101110
[2,7,4,3,5,1,6] => 101100
[2,7,4,3,5,6,1] => 101100
[2,7,4,3,6,1,5] => 101100
[2,7,4,3,6,5,1] => 101110
[2,7,4,5,1,3,6] => 100100
[2,7,4,5,1,6,3] => 101100
[2,7,4,5,3,1,6] => 101100
[2,7,4,5,3,6,1] => 101100
[2,7,4,5,6,1,3] => 100100
[2,7,4,5,6,3,1] => 101100
[2,7,4,6,1,3,5] => 100100
[2,7,4,6,1,5,3] => 101100
[2,7,4,6,3,1,5] => 101100
[2,7,4,6,3,5,1] => 101100
[2,7,4,6,5,1,3] => 100110
[2,7,4,6,5,3,1] => 101110
[2,7,5,1,3,4,6] => 100010
[2,7,5,1,3,6,4] => 100110
[2,7,5,1,4,3,6] => 101010
[2,7,5,1,4,6,3] => 101010
[2,7,5,1,6,3,4] => 101010
[2,7,5,1,6,4,3] => 101110
[2,7,5,3,1,4,6] => 101010
[2,7,5,3,1,6,4] => 101110
[2,7,5,3,4,1,6] => 101010
[2,7,5,3,4,6,1] => 101010
[2,7,5,3,6,1,4] => 101010
[2,7,5,3,6,4,1] => 101110
[2,7,5,4,1,3,6] => 100110
[2,7,5,4,1,6,3] => 101110
[2,7,5,4,3,1,6] => 101110
[2,7,5,4,3,6,1] => 101110
[2,7,5,4,6,1,3] => 100110
[2,7,5,4,6,3,1] => 101110
[2,7,5,6,1,3,4] => 100010
[2,7,5,6,1,4,3] => 101010
[2,7,5,6,3,1,4] => 101010
[2,7,5,6,3,4,1] => 101010
[2,7,5,6,4,1,3] => 100110
[2,7,5,6,4,3,1] => 101110
[2,7,6,1,3,4,5] => 100001
[2,7,6,1,3,5,4] => 100101
[2,7,6,1,4,3,5] => 101001
[2,7,6,1,4,5,3] => 101001
[2,7,6,1,5,3,4] => 101001
[2,7,6,1,5,4,3] => 101101
[2,7,6,3,1,4,5] => 101001
[2,7,6,3,1,5,4] => 101101
[2,7,6,3,4,1,5] => 101001
[2,7,6,3,4,5,1] => 101001
[2,7,6,3,5,1,4] => 101001
[2,7,6,3,5,4,1] => 101101
[2,7,6,4,1,3,5] => 100101
[2,7,6,4,1,5,3] => 101101
[2,7,6,4,3,1,5] => 101101
[2,7,6,4,3,5,1] => 101101
[2,7,6,4,5,1,3] => 100101
[2,7,6,4,5,3,1] => 101101
[2,7,6,5,1,3,4] => 100011
[2,7,6,5,1,4,3] => 101011
[2,7,6,5,3,1,4] => 101011
[2,7,6,5,3,4,1] => 101011
[2,7,6,5,4,1,3] => 100111
[2,7,6,5,4,3,1] => 101111
[3,1,2,4,5,6,7] => 100000
[3,1,2,4,5,7,6] => 100001
[3,1,2,4,6,5,7] => 100010
[3,1,2,4,6,7,5] => 100010
[3,1,2,4,7,5,6] => 100010
[3,1,2,4,7,6,5] => 100011
[3,1,2,5,4,6,7] => 100100
[3,1,2,5,4,7,6] => 100101
[3,1,2,5,6,4,7] => 100100
[3,1,2,5,6,7,4] => 100100
[3,1,2,5,7,4,6] => 100100
[3,1,2,5,7,6,4] => 100101
[3,1,2,6,4,5,7] => 100100
[3,1,2,6,4,7,5] => 100110
[3,1,2,6,5,4,7] => 100110
[3,1,2,6,5,7,4] => 100110
[3,1,2,6,7,4,5] => 100100
[3,1,2,6,7,5,4] => 100110
[3,1,2,7,4,5,6] => 100100
[3,1,2,7,4,6,5] => 100110
[3,1,2,7,5,4,6] => 100110
[3,1,2,7,5,6,4] => 100110
[3,1,2,7,6,4,5] => 100101
[3,1,2,7,6,5,4] => 100111
[3,1,4,2,5,6,7] => 110000
[3,1,4,2,5,7,6] => 110001
[3,1,4,2,6,5,7] => 110010
[3,1,4,2,6,7,5] => 110010
[3,1,4,2,7,5,6] => 110010
[3,1,4,2,7,6,5] => 110011
[3,1,4,5,2,6,7] => 110000
[3,1,4,5,2,7,6] => 110001
[3,1,4,5,6,2,7] => 110000
[3,1,4,5,6,7,2] => 110000
[3,1,4,5,7,2,6] => 110000
[3,1,4,5,7,6,2] => 110001
[3,1,4,6,2,5,7] => 110000
[3,1,4,6,2,7,5] => 110010
[3,1,4,6,5,2,7] => 110010
[3,1,4,6,5,7,2] => 110010
[3,1,4,6,7,2,5] => 110000
[3,1,4,6,7,5,2] => 110010
[3,1,4,7,2,5,6] => 110000
[3,1,4,7,2,6,5] => 110010
[3,1,4,7,5,2,6] => 110010
[3,1,4,7,5,6,2] => 110010
[3,1,4,7,6,2,5] => 110001
[3,1,4,7,6,5,2] => 110011
[3,1,5,2,4,6,7] => 110000
[3,1,5,2,4,7,6] => 110001
[3,1,5,2,6,4,7] => 110100
[3,1,5,2,6,7,4] => 110100
[3,1,5,2,7,4,6] => 110100
[3,1,5,2,7,6,4] => 110101
[3,1,5,4,2,6,7] => 110100
[3,1,5,4,2,7,6] => 110101
[3,1,5,4,6,2,7] => 110100
[3,1,5,4,6,7,2] => 110100
[3,1,5,4,7,2,6] => 110100
[3,1,5,4,7,6,2] => 110101
[3,1,5,6,2,4,7] => 110000
[3,1,5,6,2,7,4] => 110100
[3,1,5,6,4,2,7] => 110100
[3,1,5,6,4,7,2] => 110100
[3,1,5,6,7,2,4] => 110000
[3,1,5,6,7,4,2] => 110100
[3,1,5,7,2,4,6] => 110000
[3,1,5,7,2,6,4] => 110100
[3,1,5,7,4,2,6] => 110100
[3,1,5,7,4,6,2] => 110100
[3,1,5,7,6,2,4] => 110001
[3,1,5,7,6,4,2] => 110101
[3,1,6,2,4,5,7] => 110000
[3,1,6,2,4,7,5] => 110010
[3,1,6,2,5,4,7] => 110100
[3,1,6,2,5,7,4] => 110100
[3,1,6,2,7,4,5] => 110100
[3,1,6,2,7,5,4] => 110110
[3,1,6,4,2,5,7] => 110100
[3,1,6,4,2,7,5] => 110110
[3,1,6,4,5,2,7] => 110100
[3,1,6,4,5,7,2] => 110100
[3,1,6,4,7,2,5] => 110100
[3,1,6,4,7,5,2] => 110110
[3,1,6,5,2,4,7] => 110010
[3,1,6,5,2,7,4] => 110110
[3,1,6,5,4,2,7] => 110110
[3,1,6,5,4,7,2] => 110110
[3,1,6,5,7,2,4] => 110010
[3,1,6,5,7,4,2] => 110110
[3,1,6,7,2,4,5] => 110000
[3,1,6,7,2,5,4] => 110100
[3,1,6,7,4,2,5] => 110100
[3,1,6,7,4,5,2] => 110100
[3,1,6,7,5,2,4] => 110010
[3,1,6,7,5,4,2] => 110110
[3,1,7,2,4,5,6] => 110000
[3,1,7,2,4,6,5] => 110010
[3,1,7,2,5,4,6] => 110100
[3,1,7,2,5,6,4] => 110100
[3,1,7,2,6,4,5] => 110100
[3,1,7,2,6,5,4] => 110110
[3,1,7,4,2,5,6] => 110100
[3,1,7,4,2,6,5] => 110110
[3,1,7,4,5,2,6] => 110100
[3,1,7,4,5,6,2] => 110100
[3,1,7,4,6,2,5] => 110100
[3,1,7,4,6,5,2] => 110110
[3,1,7,5,2,4,6] => 110010
[3,1,7,5,2,6,4] => 110110
[3,1,7,5,4,2,6] => 110110
[3,1,7,5,4,6,2] => 110110
[3,1,7,5,6,2,4] => 110010
[3,1,7,5,6,4,2] => 110110
[3,1,7,6,2,4,5] => 110001
[3,1,7,6,2,5,4] => 110101
[3,1,7,6,4,2,5] => 110101
[3,1,7,6,4,5,2] => 110101
[3,1,7,6,5,2,4] => 110011
[3,1,7,6,5,4,2] => 110111
[3,2,1,4,5,6,7] => 110000
[3,2,1,4,5,7,6] => 110001
[3,2,1,4,6,5,7] => 110010
[3,2,1,4,6,7,5] => 110010
[3,2,1,4,7,5,6] => 110010
[3,2,1,4,7,6,5] => 110011
[3,2,1,5,4,6,7] => 110100
[3,2,1,5,4,7,6] => 110101
[3,2,1,5,6,4,7] => 110100
[3,2,1,5,6,7,4] => 110100
[3,2,1,5,7,4,6] => 110100
[3,2,1,5,7,6,4] => 110101
[3,2,1,6,4,5,7] => 110100
[3,2,1,6,4,7,5] => 110110
[3,2,1,6,5,4,7] => 110110
[3,2,1,6,5,7,4] => 110110
[3,2,1,6,7,4,5] => 110100
[3,2,1,6,7,5,4] => 110110
[3,2,1,7,4,5,6] => 110100
[3,2,1,7,4,6,5] => 110110
[3,2,1,7,5,4,6] => 110110
[3,2,1,7,5,6,4] => 110110
[3,2,1,7,6,4,5] => 110101
[3,2,1,7,6,5,4] => 110111
[3,2,4,1,5,6,7] => 110000
[3,2,4,1,5,7,6] => 110001
[3,2,4,1,6,5,7] => 110010
[3,2,4,1,6,7,5] => 110010
[3,2,4,1,7,5,6] => 110010
[3,2,4,1,7,6,5] => 110011
[3,2,4,5,1,6,7] => 110000
[3,2,4,5,1,7,6] => 110001
[3,2,4,5,6,1,7] => 110000
[3,2,4,5,6,7,1] => 110000
[3,2,4,5,7,1,6] => 110000
[3,2,4,5,7,6,1] => 110001
[3,2,4,6,1,5,7] => 110000
[3,2,4,6,1,7,5] => 110010
[3,2,4,6,5,1,7] => 110010
[3,2,4,6,5,7,1] => 110010
[3,2,4,6,7,1,5] => 110000
[3,2,4,6,7,5,1] => 110010
[3,2,4,7,1,5,6] => 110000
[3,2,4,7,1,6,5] => 110010
[3,2,4,7,5,1,6] => 110010
[3,2,4,7,5,6,1] => 110010
[3,2,4,7,6,1,5] => 110001
[3,2,4,7,6,5,1] => 110011
[3,2,5,1,4,6,7] => 110000
[3,2,5,1,4,7,6] => 110001
[3,2,5,1,6,4,7] => 110100
[3,2,5,1,6,7,4] => 110100
[3,2,5,1,7,4,6] => 110100
[3,2,5,1,7,6,4] => 110101
[3,2,5,4,1,6,7] => 110100
[3,2,5,4,1,7,6] => 110101
[3,2,5,4,6,1,7] => 110100
[3,2,5,4,6,7,1] => 110100
[3,2,5,4,7,1,6] => 110100
[3,2,5,4,7,6,1] => 110101
[3,2,5,6,1,4,7] => 110000
[3,2,5,6,1,7,4] => 110100
[3,2,5,6,4,1,7] => 110100
[3,2,5,6,4,7,1] => 110100
[3,2,5,6,7,1,4] => 110000
[3,2,5,6,7,4,1] => 110100
[3,2,5,7,1,4,6] => 110000
[3,2,5,7,1,6,4] => 110100
[3,2,5,7,4,1,6] => 110100
[3,2,5,7,4,6,1] => 110100
[3,2,5,7,6,1,4] => 110001
[3,2,5,7,6,4,1] => 110101
[3,2,6,1,4,5,7] => 110000
[3,2,6,1,4,7,5] => 110010
[3,2,6,1,5,4,7] => 110100
[3,2,6,1,5,7,4] => 110100
[3,2,6,1,7,4,5] => 110100
[3,2,6,1,7,5,4] => 110110
[3,2,6,4,1,5,7] => 110100
[3,2,6,4,1,7,5] => 110110
[3,2,6,4,5,1,7] => 110100
[3,2,6,4,5,7,1] => 110100
[3,2,6,4,7,1,5] => 110100
[3,2,6,4,7,5,1] => 110110
[3,2,6,5,1,4,7] => 110010
[3,2,6,5,1,7,4] => 110110
[3,2,6,5,4,1,7] => 110110
[3,2,6,5,4,7,1] => 110110
[3,2,6,5,7,1,4] => 110010
[3,2,6,5,7,4,1] => 110110
[3,2,6,7,1,4,5] => 110000
[3,2,6,7,1,5,4] => 110100
[3,2,6,7,4,1,5] => 110100
[3,2,6,7,4,5,1] => 110100
[3,2,6,7,5,1,4] => 110010
[3,2,6,7,5,4,1] => 110110
[3,2,7,1,4,5,6] => 110000
[3,2,7,1,4,6,5] => 110010
[3,2,7,1,5,4,6] => 110100
[3,2,7,1,5,6,4] => 110100
[3,2,7,1,6,4,5] => 110100
[3,2,7,1,6,5,4] => 110110
[3,2,7,4,1,5,6] => 110100
[3,2,7,4,1,6,5] => 110110
[3,2,7,4,5,1,6] => 110100
[3,2,7,4,5,6,1] => 110100
[3,2,7,4,6,1,5] => 110100
[3,2,7,4,6,5,1] => 110110
[3,2,7,5,1,4,6] => 110010
[3,2,7,5,1,6,4] => 110110
[3,2,7,5,4,1,6] => 110110
[3,2,7,5,4,6,1] => 110110
[3,2,7,5,6,1,4] => 110010
[3,2,7,5,6,4,1] => 110110
[3,2,7,6,1,4,5] => 110001
[3,2,7,6,1,5,4] => 110101
[3,2,7,6,4,1,5] => 110101
[3,2,7,6,4,5,1] => 110101
[3,2,7,6,5,1,4] => 110011
[3,2,7,6,5,4,1] => 110111
[3,4,1,2,5,6,7] => 100000
[3,4,1,2,5,7,6] => 100001
[3,4,1,2,6,5,7] => 100010
[3,4,1,2,6,7,5] => 100010
[3,4,1,2,7,5,6] => 100010
[3,4,1,2,7,6,5] => 100011
[3,4,1,5,2,6,7] => 110000
[3,4,1,5,2,7,6] => 110001
[3,4,1,5,6,2,7] => 110000
[3,4,1,5,6,7,2] => 110000
[3,4,1,5,7,2,6] => 110000
[3,4,1,5,7,6,2] => 110001
[3,4,1,6,2,5,7] => 110000
[3,4,1,6,2,7,5] => 110010
[3,4,1,6,5,2,7] => 110010
[3,4,1,6,5,7,2] => 110010
[3,4,1,6,7,2,5] => 110000
[3,4,1,6,7,5,2] => 110010
[3,4,1,7,2,5,6] => 110000
[3,4,1,7,2,6,5] => 110010
[3,4,1,7,5,2,6] => 110010
[3,4,1,7,5,6,2] => 110010
[3,4,1,7,6,2,5] => 110001
[3,4,1,7,6,5,2] => 110011
[3,4,2,1,5,6,7] => 110000
[3,4,2,1,5,7,6] => 110001
[3,4,2,1,6,5,7] => 110010
[3,4,2,1,6,7,5] => 110010
[3,4,2,1,7,5,6] => 110010
[3,4,2,1,7,6,5] => 110011
[3,4,2,5,1,6,7] => 110000
[3,4,2,5,1,7,6] => 110001
[3,4,2,5,6,1,7] => 110000
[3,4,2,5,6,7,1] => 110000
[3,4,2,5,7,1,6] => 110000
[3,4,2,5,7,6,1] => 110001
[3,4,2,6,1,5,7] => 110000
[3,4,2,6,1,7,5] => 110010
[3,4,2,6,5,1,7] => 110010
[3,4,2,6,5,7,1] => 110010
[3,4,2,6,7,1,5] => 110000
[3,4,2,6,7,5,1] => 110010
[3,4,2,7,1,5,6] => 110000
[3,4,2,7,1,6,5] => 110010
[3,4,2,7,5,1,6] => 110010
[3,4,2,7,5,6,1] => 110010
[3,4,2,7,6,1,5] => 110001
[3,4,2,7,6,5,1] => 110011
[3,4,5,1,2,6,7] => 100000
[3,4,5,1,2,7,6] => 100001
[3,4,5,1,6,2,7] => 110000
[3,4,5,1,6,7,2] => 110000
[3,4,5,1,7,2,6] => 110000
[3,4,5,1,7,6,2] => 110001
[3,4,5,2,1,6,7] => 110000
[3,4,5,2,1,7,6] => 110001
[3,4,5,2,6,1,7] => 110000
[3,4,5,2,6,7,1] => 110000
[3,4,5,2,7,1,6] => 110000
[3,4,5,2,7,6,1] => 110001
[3,4,5,6,1,2,7] => 100000
[3,4,5,6,1,7,2] => 110000
[3,4,5,6,2,1,7] => 110000
[3,4,5,6,2,7,1] => 110000
[3,4,5,6,7,1,2] => 100000
[3,4,5,6,7,2,1] => 110000
[3,4,5,7,1,2,6] => 100000
[3,4,5,7,1,6,2] => 110000
[3,4,5,7,2,1,6] => 110000
[3,4,5,7,2,6,1] => 110000
[3,4,5,7,6,1,2] => 100001
[3,4,5,7,6,2,1] => 110001
[3,4,6,1,2,5,7] => 100000
[3,4,6,1,2,7,5] => 100010
[3,4,6,1,5,2,7] => 110000
[3,4,6,1,5,7,2] => 110000
[3,4,6,1,7,2,5] => 110000
[3,4,6,1,7,5,2] => 110010
[3,4,6,2,1,5,7] => 110000
[3,4,6,2,1,7,5] => 110010
[3,4,6,2,5,1,7] => 110000
[3,4,6,2,5,7,1] => 110000
[3,4,6,2,7,1,5] => 110000
[3,4,6,2,7,5,1] => 110010
[3,4,6,5,1,2,7] => 100010
[3,4,6,5,1,7,2] => 110010
[3,4,6,5,2,1,7] => 110010
[3,4,6,5,2,7,1] => 110010
[3,4,6,5,7,1,2] => 100010
[3,4,6,5,7,2,1] => 110010
[3,4,6,7,1,2,5] => 100000
[3,4,6,7,1,5,2] => 110000
[3,4,6,7,2,1,5] => 110000
[3,4,6,7,2,5,1] => 110000
[3,4,6,7,5,1,2] => 100010
[3,4,6,7,5,2,1] => 110010
[3,4,7,1,2,5,6] => 100000
[3,4,7,1,2,6,5] => 100010
[3,4,7,1,5,2,6] => 110000
[3,4,7,1,5,6,2] => 110000
[3,4,7,1,6,2,5] => 110000
[3,4,7,1,6,5,2] => 110010
[3,4,7,2,1,5,6] => 110000
[3,4,7,2,1,6,5] => 110010
[3,4,7,2,5,1,6] => 110000
[3,4,7,2,5,6,1] => 110000
[3,4,7,2,6,1,5] => 110000
[3,4,7,2,6,5,1] => 110010
[3,4,7,5,1,2,6] => 100010
[3,4,7,5,1,6,2] => 110010
[3,4,7,5,2,1,6] => 110010
[3,4,7,5,2,6,1] => 110010
[3,4,7,5,6,1,2] => 100010
[3,4,7,5,6,2,1] => 110010
[3,4,7,6,1,2,5] => 100001
[3,4,7,6,1,5,2] => 110001
[3,4,7,6,2,1,5] => 110001
[3,4,7,6,2,5,1] => 110001
[3,4,7,6,5,1,2] => 100011
[3,4,7,6,5,2,1] => 110011
[3,5,1,2,4,6,7] => 100000
[3,5,1,2,4,7,6] => 100001
[3,5,1,2,6,4,7] => 100100
[3,5,1,2,6,7,4] => 100100
[3,5,1,2,7,4,6] => 100100
[3,5,1,2,7,6,4] => 100101
[3,5,1,4,2,6,7] => 110000
[3,5,1,4,2,7,6] => 110001
[3,5,1,4,6,2,7] => 110000
[3,5,1,4,6,7,2] => 110000
[3,5,1,4,7,2,6] => 110000
[3,5,1,4,7,6,2] => 110001
[3,5,1,6,2,4,7] => 110000
[3,5,1,6,2,7,4] => 110100
[3,5,1,6,4,2,7] => 110100
[3,5,1,6,4,7,2] => 110100
[3,5,1,6,7,2,4] => 110000
[3,5,1,6,7,4,2] => 110100
[3,5,1,7,2,4,6] => 110000
[3,5,1,7,2,6,4] => 110100
[3,5,1,7,4,2,6] => 110100
[3,5,1,7,4,6,2] => 110100
[3,5,1,7,6,2,4] => 110001
[3,5,1,7,6,4,2] => 110101
[3,5,2,1,4,6,7] => 110000
[3,5,2,1,4,7,6] => 110001
[3,5,2,1,6,4,7] => 110100
[3,5,2,1,6,7,4] => 110100
[3,5,2,1,7,4,6] => 110100
[3,5,2,1,7,6,4] => 110101
[3,5,2,4,1,6,7] => 110000
[3,5,2,4,1,7,6] => 110001
[3,5,2,4,6,1,7] => 110000
[3,5,2,4,6,7,1] => 110000
[3,5,2,4,7,1,6] => 110000
[3,5,2,4,7,6,1] => 110001
[3,5,2,6,1,4,7] => 110000
[3,5,2,6,1,7,4] => 110100
[3,5,2,6,4,1,7] => 110100
[3,5,2,6,4,7,1] => 110100
[3,5,2,6,7,1,4] => 110000
[3,5,2,6,7,4,1] => 110100
[3,5,2,7,1,4,6] => 110000
[3,5,2,7,1,6,4] => 110100
[3,5,2,7,4,1,6] => 110100
[3,5,2,7,4,6,1] => 110100
[3,5,2,7,6,1,4] => 110001
[3,5,2,7,6,4,1] => 110101
[3,5,4,1,2,6,7] => 100100
[3,5,4,1,2,7,6] => 100101
[3,5,4,1,6,2,7] => 110100
[3,5,4,1,6,7,2] => 110100
[3,5,4,1,7,2,6] => 110100
[3,5,4,1,7,6,2] => 110101
[3,5,4,2,1,6,7] => 110100
[3,5,4,2,1,7,6] => 110101
[3,5,4,2,6,1,7] => 110100
[3,5,4,2,6,7,1] => 110100
[3,5,4,2,7,1,6] => 110100
[3,5,4,2,7,6,1] => 110101
[3,5,4,6,1,2,7] => 100100
[3,5,4,6,1,7,2] => 110100
[3,5,4,6,2,1,7] => 110100
[3,5,4,6,2,7,1] => 110100
[3,5,4,6,7,1,2] => 100100
[3,5,4,6,7,2,1] => 110100
[3,5,4,7,1,2,6] => 100100
[3,5,4,7,1,6,2] => 110100
[3,5,4,7,2,1,6] => 110100
[3,5,4,7,2,6,1] => 110100
[3,5,4,7,6,1,2] => 100101
[3,5,4,7,6,2,1] => 110101
[3,5,6,1,2,4,7] => 100000
[3,5,6,1,2,7,4] => 100100
[3,5,6,1,4,2,7] => 110000
[3,5,6,1,4,7,2] => 110000
[3,5,6,1,7,2,4] => 110000
[3,5,6,1,7,4,2] => 110100
[3,5,6,2,1,4,7] => 110000
[3,5,6,2,1,7,4] => 110100
[3,5,6,2,4,1,7] => 110000
[3,5,6,2,4,7,1] => 110000
[3,5,6,2,7,1,4] => 110000
[3,5,6,2,7,4,1] => 110100
[3,5,6,4,1,2,7] => 100100
[3,5,6,4,1,7,2] => 110100
[3,5,6,4,2,1,7] => 110100
[3,5,6,4,2,7,1] => 110100
[3,5,6,4,7,1,2] => 100100
[3,5,6,4,7,2,1] => 110100
[3,5,6,7,1,2,4] => 100000
[3,5,6,7,1,4,2] => 110000
[3,5,6,7,2,1,4] => 110000
[3,5,6,7,2,4,1] => 110000
[3,5,6,7,4,1,2] => 100100
[3,5,6,7,4,2,1] => 110100
[3,5,7,1,2,4,6] => 100000
[3,5,7,1,2,6,4] => 100100
[3,5,7,1,4,2,6] => 110000
[3,5,7,1,4,6,2] => 110000
[3,5,7,1,6,2,4] => 110000
[3,5,7,1,6,4,2] => 110100
[3,5,7,2,1,4,6] => 110000
[3,5,7,2,1,6,4] => 110100
[3,5,7,2,4,1,6] => 110000
[3,5,7,2,4,6,1] => 110000
[3,5,7,2,6,1,4] => 110000
[3,5,7,2,6,4,1] => 110100
[3,5,7,4,1,2,6] => 100100
[3,5,7,4,1,6,2] => 110100
[3,5,7,4,2,1,6] => 110100
[3,5,7,4,2,6,1] => 110100
[3,5,7,4,6,1,2] => 100100
[3,5,7,4,6,2,1] => 110100
[3,5,7,6,1,2,4] => 100001
[3,5,7,6,1,4,2] => 110001
[3,5,7,6,2,1,4] => 110001
[3,5,7,6,2,4,1] => 110001
[3,5,7,6,4,1,2] => 100101
[3,5,7,6,4,2,1] => 110101
[3,6,1,2,4,5,7] => 100000
[3,6,1,2,4,7,5] => 100010
[3,6,1,2,5,4,7] => 100100
[3,6,1,2,5,7,4] => 100100
[3,6,1,2,7,4,5] => 100100
[3,6,1,2,7,5,4] => 100110
[3,6,1,4,2,5,7] => 110000
[3,6,1,4,2,7,5] => 110010
[3,6,1,4,5,2,7] => 110000
[3,6,1,4,5,7,2] => 110000
[3,6,1,4,7,2,5] => 110000
[3,6,1,4,7,5,2] => 110010
[3,6,1,5,2,4,7] => 110000
[3,6,1,5,2,7,4] => 110100
[3,6,1,5,4,2,7] => 110100
[3,6,1,5,4,7,2] => 110100
[3,6,1,5,7,2,4] => 110000
[3,6,1,5,7,4,2] => 110100
[3,6,1,7,2,4,5] => 110000
[3,6,1,7,2,5,4] => 110100
[3,6,1,7,4,2,5] => 110100
[3,6,1,7,4,5,2] => 110100
[3,6,1,7,5,2,4] => 110010
[3,6,1,7,5,4,2] => 110110
[3,6,2,1,4,5,7] => 110000
[3,6,2,1,4,7,5] => 110010
[3,6,2,1,5,4,7] => 110100
[3,6,2,1,5,7,4] => 110100
[3,6,2,1,7,4,5] => 110100
[3,6,2,1,7,5,4] => 110110
[3,6,2,4,1,5,7] => 110000
[3,6,2,4,1,7,5] => 110010
[3,6,2,4,5,1,7] => 110000
[3,6,2,4,5,7,1] => 110000
[3,6,2,4,7,1,5] => 110000
[3,6,2,4,7,5,1] => 110010
[3,6,2,5,1,4,7] => 110000
[3,6,2,5,1,7,4] => 110100
[3,6,2,5,4,1,7] => 110100
[3,6,2,5,4,7,1] => 110100
[3,6,2,5,7,1,4] => 110000
[3,6,2,5,7,4,1] => 110100
[3,6,2,7,1,4,5] => 110000
[3,6,2,7,1,5,4] => 110100
[3,6,2,7,4,1,5] => 110100
[3,6,2,7,4,5,1] => 110100
[3,6,2,7,5,1,4] => 110010
[3,6,2,7,5,4,1] => 110110
[3,6,4,1,2,5,7] => 100100
[3,6,4,1,2,7,5] => 100110
[3,6,4,1,5,2,7] => 110100
[3,6,4,1,5,7,2] => 110100
[3,6,4,1,7,2,5] => 110100
[3,6,4,1,7,5,2] => 110110
[3,6,4,2,1,5,7] => 110100
[3,6,4,2,1,7,5] => 110110
[3,6,4,2,5,1,7] => 110100
[3,6,4,2,5,7,1] => 110100
[3,6,4,2,7,1,5] => 110100
[3,6,4,2,7,5,1] => 110110
[3,6,4,5,1,2,7] => 100100
[3,6,4,5,1,7,2] => 110100
[3,6,4,5,2,1,7] => 110100
[3,6,4,5,2,7,1] => 110100
[3,6,4,5,7,1,2] => 100100
[3,6,4,5,7,2,1] => 110100
[3,6,4,7,1,2,5] => 100100
[3,6,4,7,1,5,2] => 110100
[3,6,4,7,2,1,5] => 110100
[3,6,4,7,2,5,1] => 110100
[3,6,4,7,5,1,2] => 100110
[3,6,4,7,5,2,1] => 110110
[3,6,5,1,2,4,7] => 100010
[3,6,5,1,2,7,4] => 100110
[3,6,5,1,4,2,7] => 110010
[3,6,5,1,4,7,2] => 110010
[3,6,5,1,7,2,4] => 110010
[3,6,5,1,7,4,2] => 110110
[3,6,5,2,1,4,7] => 110010
[3,6,5,2,1,7,4] => 110110
[3,6,5,2,4,1,7] => 110010
[3,6,5,2,4,7,1] => 110010
[3,6,5,2,7,1,4] => 110010
[3,6,5,2,7,4,1] => 110110
[3,6,5,4,1,2,7] => 100110
[3,6,5,4,1,7,2] => 110110
[3,6,5,4,2,1,7] => 110110
[3,6,5,4,2,7,1] => 110110
[3,6,5,4,7,1,2] => 100110
[3,6,5,4,7,2,1] => 110110
[3,6,5,7,1,2,4] => 100010
[3,6,5,7,1,4,2] => 110010
[3,6,5,7,2,1,4] => 110010
[3,6,5,7,2,4,1] => 110010
[3,6,5,7,4,1,2] => 100110
[3,6,5,7,4,2,1] => 110110
[3,6,7,1,2,4,5] => 100000
[3,6,7,1,2,5,4] => 100100
[3,6,7,1,4,2,5] => 110000
[3,6,7,1,4,5,2] => 110000
[3,6,7,1,5,2,4] => 110000
[3,6,7,1,5,4,2] => 110100
[3,6,7,2,1,4,5] => 110000
[3,6,7,2,1,5,4] => 110100
[3,6,7,2,4,1,5] => 110000
[3,6,7,2,4,5,1] => 110000
[3,6,7,2,5,1,4] => 110000
[3,6,7,2,5,4,1] => 110100
[3,6,7,4,1,2,5] => 100100
[3,6,7,4,1,5,2] => 110100
[3,6,7,4,2,1,5] => 110100
[3,6,7,4,2,5,1] => 110100
[3,6,7,4,5,1,2] => 100100
[3,6,7,4,5,2,1] => 110100
[3,6,7,5,1,2,4] => 100010
[3,6,7,5,1,4,2] => 110010
[3,6,7,5,2,1,4] => 110010
[3,6,7,5,2,4,1] => 110010
[3,6,7,5,4,1,2] => 100110
[3,6,7,5,4,2,1] => 110110
[3,7,1,2,4,5,6] => 100000
[3,7,1,2,4,6,5] => 100010
[3,7,1,2,5,4,6] => 100100
[3,7,1,2,5,6,4] => 100100
[3,7,1,2,6,4,5] => 100100
[3,7,1,2,6,5,4] => 100110
[3,7,1,4,2,5,6] => 110000
[3,7,1,4,2,6,5] => 110010
[3,7,1,4,5,2,6] => 110000
[3,7,1,4,5,6,2] => 110000
[3,7,1,4,6,2,5] => 110000
[3,7,1,4,6,5,2] => 110010
[3,7,1,5,2,4,6] => 110000
[3,7,1,5,2,6,4] => 110100
[3,7,1,5,4,2,6] => 110100
[3,7,1,5,4,6,2] => 110100
[3,7,1,5,6,2,4] => 110000
[3,7,1,5,6,4,2] => 110100
[3,7,1,6,2,4,5] => 110000
[3,7,1,6,2,5,4] => 110100
[3,7,1,6,4,2,5] => 110100
[3,7,1,6,4,5,2] => 110100
[3,7,1,6,5,2,4] => 110010
[3,7,1,6,5,4,2] => 110110
[3,7,2,1,4,5,6] => 110000
[3,7,2,1,4,6,5] => 110010
[3,7,2,1,5,4,6] => 110100
[3,7,2,1,5,6,4] => 110100
[3,7,2,1,6,4,5] => 110100
[3,7,2,1,6,5,4] => 110110
[3,7,2,4,1,5,6] => 110000
[3,7,2,4,1,6,5] => 110010
[3,7,2,4,5,1,6] => 110000
[3,7,2,4,5,6,1] => 110000
[3,7,2,4,6,1,5] => 110000
[3,7,2,4,6,5,1] => 110010
[3,7,2,5,1,4,6] => 110000
[3,7,2,5,1,6,4] => 110100
[3,7,2,5,4,1,6] => 110100
[3,7,2,5,4,6,1] => 110100
[3,7,2,5,6,1,4] => 110000
[3,7,2,5,6,4,1] => 110100
[3,7,2,6,1,4,5] => 110000
[3,7,2,6,1,5,4] => 110100
[3,7,2,6,4,1,5] => 110100
[3,7,2,6,4,5,1] => 110100
[3,7,2,6,5,1,4] => 110010
[3,7,2,6,5,4,1] => 110110
[3,7,4,1,2,5,6] => 100100
[3,7,4,1,2,6,5] => 100110
[3,7,4,1,5,2,6] => 110100
[3,7,4,1,5,6,2] => 110100
[3,7,4,1,6,2,5] => 110100
[3,7,4,1,6,5,2] => 110110
[3,7,4,2,1,5,6] => 110100
[3,7,4,2,1,6,5] => 110110
[3,7,4,2,5,1,6] => 110100
[3,7,4,2,5,6,1] => 110100
[3,7,4,2,6,1,5] => 110100
[3,7,4,2,6,5,1] => 110110
[3,7,4,5,1,2,6] => 100100
[3,7,4,5,1,6,2] => 110100
[3,7,4,5,2,1,6] => 110100
[3,7,4,5,2,6,1] => 110100
[3,7,4,5,6,1,2] => 100100
[3,7,4,5,6,2,1] => 110100
[3,7,4,6,1,2,5] => 100100
[3,7,4,6,1,5,2] => 110100
[3,7,4,6,2,1,5] => 110100
[3,7,4,6,2,5,1] => 110100
[3,7,4,6,5,1,2] => 100110
[3,7,4,6,5,2,1] => 110110
[3,7,5,1,2,4,6] => 100010
[3,7,5,1,2,6,4] => 100110
[3,7,5,1,4,2,6] => 110010
[3,7,5,1,4,6,2] => 110010
[3,7,5,1,6,2,4] => 110010
[3,7,5,1,6,4,2] => 110110
[3,7,5,2,1,4,6] => 110010
[3,7,5,2,1,6,4] => 110110
[3,7,5,2,4,1,6] => 110010
[3,7,5,2,4,6,1] => 110010
[3,7,5,2,6,1,4] => 110010
[3,7,5,2,6,4,1] => 110110
[3,7,5,4,1,2,6] => 100110
[3,7,5,4,1,6,2] => 110110
[3,7,5,4,2,1,6] => 110110
[3,7,5,4,2,6,1] => 110110
[3,7,5,4,6,1,2] => 100110
[3,7,5,4,6,2,1] => 110110
[3,7,5,6,1,2,4] => 100010
[3,7,5,6,1,4,2] => 110010
[3,7,5,6,2,1,4] => 110010
[3,7,5,6,2,4,1] => 110010
[3,7,5,6,4,1,2] => 100110
[3,7,5,6,4,2,1] => 110110
[3,7,6,1,2,4,5] => 100001
[3,7,6,1,2,5,4] => 100101
[3,7,6,1,4,2,5] => 110001
[3,7,6,1,4,5,2] => 110001
[3,7,6,1,5,2,4] => 110001
[3,7,6,1,5,4,2] => 110101
[3,7,6,2,1,4,5] => 110001
[3,7,6,2,1,5,4] => 110101
[3,7,6,2,4,1,5] => 110001
[3,7,6,2,4,5,1] => 110001
[3,7,6,2,5,1,4] => 110001
[3,7,6,2,5,4,1] => 110101
[3,7,6,4,1,2,5] => 100101
[3,7,6,4,1,5,2] => 110101
[3,7,6,4,2,1,5] => 110101
[3,7,6,4,2,5,1] => 110101
[3,7,6,4,5,1,2] => 100101
[3,7,6,4,5,2,1] => 110101
[3,7,6,5,1,2,4] => 100011
[3,7,6,5,1,4,2] => 110011
[3,7,6,5,2,1,4] => 110011
[3,7,6,5,2,4,1] => 110011
[3,7,6,5,4,1,2] => 100111
[3,7,6,5,4,2,1] => 110111
[4,1,2,3,5,6,7] => 100000
[4,1,2,3,5,7,6] => 100001
[4,1,2,3,6,5,7] => 100010
[4,1,2,3,6,7,5] => 100010
[4,1,2,3,7,5,6] => 100010
[4,1,2,3,7,6,5] => 100011
[4,1,2,5,3,6,7] => 101000
[4,1,2,5,3,7,6] => 101001
[4,1,2,5,6,3,7] => 101000
[4,1,2,5,6,7,3] => 101000
[4,1,2,5,7,3,6] => 101000
[4,1,2,5,7,6,3] => 101001
[4,1,2,6,3,5,7] => 101000
[4,1,2,6,3,7,5] => 101010
[4,1,2,6,5,3,7] => 101010
[4,1,2,6,5,7,3] => 101010
[4,1,2,6,7,3,5] => 101000
[4,1,2,6,7,5,3] => 101010
[4,1,2,7,3,5,6] => 101000
[4,1,2,7,3,6,5] => 101010
[4,1,2,7,5,3,6] => 101010
[4,1,2,7,5,6,3] => 101010
[4,1,2,7,6,3,5] => 101001
[4,1,2,7,6,5,3] => 101011
[4,1,3,2,5,6,7] => 110000
[4,1,3,2,5,7,6] => 110001
[4,1,3,2,6,5,7] => 110010
[4,1,3,2,6,7,5] => 110010
[4,1,3,2,7,5,6] => 110010
[4,1,3,2,7,6,5] => 110011
[4,1,3,5,2,6,7] => 110000
[4,1,3,5,2,7,6] => 110001
[4,1,3,5,6,2,7] => 110000
[4,1,3,5,6,7,2] => 110000
[4,1,3,5,7,2,6] => 110000
[4,1,3,5,7,6,2] => 110001
[4,1,3,6,2,5,7] => 110000
[4,1,3,6,2,7,5] => 110010
[4,1,3,6,5,2,7] => 110010
[4,1,3,6,5,7,2] => 110010
[4,1,3,6,7,2,5] => 110000
[4,1,3,6,7,5,2] => 110010
[4,1,3,7,2,5,6] => 110000
[4,1,3,7,2,6,5] => 110010
[4,1,3,7,5,2,6] => 110010
[4,1,3,7,5,6,2] => 110010
[4,1,3,7,6,2,5] => 110001
[4,1,3,7,6,5,2] => 110011
[4,1,5,2,3,6,7] => 110000
[4,1,5,2,3,7,6] => 110001
[4,1,5,2,6,3,7] => 111000
[4,1,5,2,6,7,3] => 111000
[4,1,5,2,7,3,6] => 111000
[4,1,5,2,7,6,3] => 111001
[4,1,5,3,2,6,7] => 111000
[4,1,5,3,2,7,6] => 111001
[4,1,5,3,6,2,7] => 111000
[4,1,5,3,6,7,2] => 111000
[4,1,5,3,7,2,6] => 111000
[4,1,5,3,7,6,2] => 111001
[4,1,5,6,2,3,7] => 110000
[4,1,5,6,2,7,3] => 111000
[4,1,5,6,3,2,7] => 111000
[4,1,5,6,3,7,2] => 111000
[4,1,5,6,7,2,3] => 110000
[4,1,5,6,7,3,2] => 111000
[4,1,5,7,2,3,6] => 110000
[4,1,5,7,2,6,3] => 111000
[4,1,5,7,3,2,6] => 111000
[4,1,5,7,3,6,2] => 111000
[4,1,5,7,6,2,3] => 110001
[4,1,5,7,6,3,2] => 111001
[4,1,6,2,3,5,7] => 110000
[4,1,6,2,3,7,5] => 110010
[4,1,6,2,5,3,7] => 111000
[4,1,6,2,5,7,3] => 111000
[4,1,6,2,7,3,5] => 111000
[4,1,6,2,7,5,3] => 111010
[4,1,6,3,2,5,7] => 111000
[4,1,6,3,2,7,5] => 111010
[4,1,6,3,5,2,7] => 111000
[4,1,6,3,5,7,2] => 111000
[4,1,6,3,7,2,5] => 111000
[4,1,6,3,7,5,2] => 111010
[4,1,6,5,2,3,7] => 110010
[4,1,6,5,2,7,3] => 111010
[4,1,6,5,3,2,7] => 111010
[4,1,6,5,3,7,2] => 111010
[4,1,6,5,7,2,3] => 110010
[4,1,6,5,7,3,2] => 111010
[4,1,6,7,2,3,5] => 110000
[4,1,6,7,2,5,3] => 111000
[4,1,6,7,3,2,5] => 111000
[4,1,6,7,3,5,2] => 111000
[4,1,6,7,5,2,3] => 110010
[4,1,6,7,5,3,2] => 111010
[4,1,7,2,3,5,6] => 110000
[4,1,7,2,3,6,5] => 110010
[4,1,7,2,5,3,6] => 111000
[4,1,7,2,5,6,3] => 111000
[4,1,7,2,6,3,5] => 111000
[4,1,7,2,6,5,3] => 111010
[4,1,7,3,2,5,6] => 111000
[4,1,7,3,2,6,5] => 111010
[4,1,7,3,5,2,6] => 111000
[4,1,7,3,5,6,2] => 111000
[4,1,7,3,6,2,5] => 111000
[4,1,7,3,6,5,2] => 111010
[4,1,7,5,2,3,6] => 110010
[4,1,7,5,2,6,3] => 111010
[4,1,7,5,3,2,6] => 111010
[4,1,7,5,3,6,2] => 111010
[4,1,7,5,6,2,3] => 110010
[4,1,7,5,6,3,2] => 111010
[4,1,7,6,2,3,5] => 110001
[4,1,7,6,2,5,3] => 111001
[4,1,7,6,3,2,5] => 111001
[4,1,7,6,3,5,2] => 111001
[4,1,7,6,5,2,3] => 110011
[4,1,7,6,5,3,2] => 111011
[4,2,1,3,5,6,7] => 110000
[4,2,1,3,5,7,6] => 110001
[4,2,1,3,6,5,7] => 110010
[4,2,1,3,6,7,5] => 110010
[4,2,1,3,7,5,6] => 110010
[4,2,1,3,7,6,5] => 110011
[4,2,1,5,3,6,7] => 111000
[4,2,1,5,3,7,6] => 111001
[4,2,1,5,6,3,7] => 111000
[4,2,1,5,6,7,3] => 111000
[4,2,1,5,7,3,6] => 111000
[4,2,1,5,7,6,3] => 111001
[4,2,1,6,3,5,7] => 111000
[4,2,1,6,3,7,5] => 111010
[4,2,1,6,5,3,7] => 111010
[4,2,1,6,5,7,3] => 111010
[4,2,1,6,7,3,5] => 111000
[4,2,1,6,7,5,3] => 111010
[4,2,1,7,3,5,6] => 111000
[4,2,1,7,3,6,5] => 111010
[4,2,1,7,5,3,6] => 111010
[4,2,1,7,5,6,3] => 111010
[4,2,1,7,6,3,5] => 111001
[4,2,1,7,6,5,3] => 111011
[4,2,3,1,5,6,7] => 110000
[4,2,3,1,5,7,6] => 110001
[4,2,3,1,6,5,7] => 110010
[4,2,3,1,6,7,5] => 110010
[4,2,3,1,7,5,6] => 110010
[4,2,3,1,7,6,5] => 110011
[4,2,3,5,1,6,7] => 110000
[4,2,3,5,1,7,6] => 110001
[4,2,3,5,6,1,7] => 110000
[4,2,3,5,6,7,1] => 110000
[4,2,3,5,7,1,6] => 110000
[4,2,3,5,7,6,1] => 110001
[4,2,3,6,1,5,7] => 110000
[4,2,3,6,1,7,5] => 110010
[4,2,3,6,5,1,7] => 110010
[4,2,3,6,5,7,1] => 110010
[4,2,3,6,7,1,5] => 110000
[4,2,3,6,7,5,1] => 110010
[4,2,3,7,1,5,6] => 110000
[4,2,3,7,1,6,5] => 110010
[4,2,3,7,5,1,6] => 110010
[4,2,3,7,5,6,1] => 110010
[4,2,3,7,6,1,5] => 110001
[4,2,3,7,6,5,1] => 110011
[4,2,5,1,3,6,7] => 110000
[4,2,5,1,3,7,6] => 110001
[4,2,5,1,6,3,7] => 111000
[4,2,5,1,6,7,3] => 111000
[4,2,5,1,7,3,6] => 111000
[4,2,5,1,7,6,3] => 111001
[4,2,5,3,1,6,7] => 111000
[4,2,5,3,1,7,6] => 111001
[4,2,5,3,6,1,7] => 111000
[4,2,5,3,6,7,1] => 111000
[4,2,5,3,7,1,6] => 111000
[4,2,5,3,7,6,1] => 111001
[4,2,5,6,1,3,7] => 110000
[4,2,5,6,1,7,3] => 111000
[4,2,5,6,3,1,7] => 111000
[4,2,5,6,3,7,1] => 111000
[4,2,5,6,7,1,3] => 110000
[4,2,5,6,7,3,1] => 111000
[4,2,5,7,1,3,6] => 110000
[4,2,5,7,1,6,3] => 111000
[4,2,5,7,3,1,6] => 111000
[4,2,5,7,3,6,1] => 111000
[4,2,5,7,6,1,3] => 110001
[4,2,5,7,6,3,1] => 111001
[4,2,6,1,3,5,7] => 110000
[4,2,6,1,3,7,5] => 110010
[4,2,6,1,5,3,7] => 111000
[4,2,6,1,5,7,3] => 111000
[4,2,6,1,7,3,5] => 111000
[4,2,6,1,7,5,3] => 111010
[4,2,6,3,1,5,7] => 111000
[4,2,6,3,1,7,5] => 111010
[4,2,6,3,5,1,7] => 111000
[4,2,6,3,5,7,1] => 111000
[4,2,6,3,7,1,5] => 111000
[4,2,6,3,7,5,1] => 111010
[4,2,6,5,1,3,7] => 110010
[4,2,6,5,1,7,3] => 111010
[4,2,6,5,3,1,7] => 111010
[4,2,6,5,3,7,1] => 111010
[4,2,6,5,7,1,3] => 110010
[4,2,6,5,7,3,1] => 111010
[4,2,6,7,1,3,5] => 110000
[4,2,6,7,1,5,3] => 111000
[4,2,6,7,3,1,5] => 111000
[4,2,6,7,3,5,1] => 111000
[4,2,6,7,5,1,3] => 110010
[4,2,6,7,5,3,1] => 111010
[4,2,7,1,3,5,6] => 110000
[4,2,7,1,3,6,5] => 110010
[4,2,7,1,5,3,6] => 111000
[4,2,7,1,5,6,3] => 111000
[4,2,7,1,6,3,5] => 111000
[4,2,7,1,6,5,3] => 111010
[4,2,7,3,1,5,6] => 111000
[4,2,7,3,1,6,5] => 111010
[4,2,7,3,5,1,6] => 111000
[4,2,7,3,5,6,1] => 111000
[4,2,7,3,6,1,5] => 111000
[4,2,7,3,6,5,1] => 111010
[4,2,7,5,1,3,6] => 110010
[4,2,7,5,1,6,3] => 111010
[4,2,7,5,3,1,6] => 111010
[4,2,7,5,3,6,1] => 111010
[4,2,7,5,6,1,3] => 110010
[4,2,7,5,6,3,1] => 111010
[4,2,7,6,1,3,5] => 110001
[4,2,7,6,1,5,3] => 111001
[4,2,7,6,3,1,5] => 111001
[4,2,7,6,3,5,1] => 111001
[4,2,7,6,5,1,3] => 110011
[4,2,7,6,5,3,1] => 111011
[4,3,1,2,5,6,7] => 101000
[4,3,1,2,5,7,6] => 101001
[4,3,1,2,6,5,7] => 101010
[4,3,1,2,6,7,5] => 101010
[4,3,1,2,7,5,6] => 101010
[4,3,1,2,7,6,5] => 101011
[4,3,1,5,2,6,7] => 111000
[4,3,1,5,2,7,6] => 111001
[4,3,1,5,6,2,7] => 111000
[4,3,1,5,6,7,2] => 111000
[4,3,1,5,7,2,6] => 111000
[4,3,1,5,7,6,2] => 111001
[4,3,1,6,2,5,7] => 111000
[4,3,1,6,2,7,5] => 111010
[4,3,1,6,5,2,7] => 111010
[4,3,1,6,5,7,2] => 111010
[4,3,1,6,7,2,5] => 111000
[4,3,1,6,7,5,2] => 111010
[4,3,1,7,2,5,6] => 111000
[4,3,1,7,2,6,5] => 111010
[4,3,1,7,5,2,6] => 111010
[4,3,1,7,5,6,2] => 111010
[4,3,1,7,6,2,5] => 111001
[4,3,1,7,6,5,2] => 111011
[4,3,2,1,5,6,7] => 111000
[4,3,2,1,5,7,6] => 111001
[4,3,2,1,6,5,7] => 111010
[4,3,2,1,6,7,5] => 111010
[4,3,2,1,7,5,6] => 111010
[4,3,2,1,7,6,5] => 111011
[4,3,2,5,1,6,7] => 111000
[4,3,2,5,1,7,6] => 111001
[4,3,2,5,6,1,7] => 111000
[4,3,2,5,6,7,1] => 111000
[4,3,2,5,7,1,6] => 111000
[4,3,2,5,7,6,1] => 111001
[4,3,2,6,1,5,7] => 111000
[4,3,2,6,1,7,5] => 111010
[4,3,2,6,5,1,7] => 111010
[4,3,2,6,5,7,1] => 111010
[4,3,2,6,7,1,5] => 111000
[4,3,2,6,7,5,1] => 111010
[4,3,2,7,1,5,6] => 111000
[4,3,2,7,1,6,5] => 111010
[4,3,2,7,5,1,6] => 111010
[4,3,2,7,5,6,1] => 111010
[4,3,2,7,6,1,5] => 111001
[4,3,2,7,6,5,1] => 111011
[4,3,5,1,2,6,7] => 101000
[4,3,5,1,2,7,6] => 101001
[4,3,5,1,6,2,7] => 111000
[4,3,5,1,6,7,2] => 111000
[4,3,5,1,7,2,6] => 111000
[4,3,5,1,7,6,2] => 111001
[4,3,5,2,1,6,7] => 111000
[4,3,5,2,1,7,6] => 111001
[4,3,5,2,6,1,7] => 111000
[4,3,5,2,6,7,1] => 111000
[4,3,5,2,7,1,6] => 111000
[4,3,5,2,7,6,1] => 111001
[4,3,5,6,1,2,7] => 101000
[4,3,5,6,1,7,2] => 111000
[4,3,5,6,2,1,7] => 111000
[4,3,5,6,2,7,1] => 111000
[4,3,5,6,7,1,2] => 101000
[4,3,5,6,7,2,1] => 111000
[4,3,5,7,1,2,6] => 101000
[4,3,5,7,1,6,2] => 111000
[4,3,5,7,2,1,6] => 111000
[4,3,5,7,2,6,1] => 111000
[4,3,5,7,6,1,2] => 101001
[4,3,5,7,6,2,1] => 111001
[4,3,6,1,2,5,7] => 101000
[4,3,6,1,2,7,5] => 101010
[4,3,6,1,5,2,7] => 111000
[4,3,6,1,5,7,2] => 111000
[4,3,6,1,7,2,5] => 111000
[4,3,6,1,7,5,2] => 111010
[4,3,6,2,1,5,7] => 111000
[4,3,6,2,1,7,5] => 111010
[4,3,6,2,5,1,7] => 111000
[4,3,6,2,5,7,1] => 111000
[4,3,6,2,7,1,5] => 111000
[4,3,6,2,7,5,1] => 111010
[4,3,6,5,1,2,7] => 101010
[4,3,6,5,1,7,2] => 111010
[4,3,6,5,2,1,7] => 111010
[4,3,6,5,2,7,1] => 111010
[4,3,6,5,7,1,2] => 101010
[4,3,6,5,7,2,1] => 111010
[4,3,6,7,1,2,5] => 101000
[4,3,6,7,1,5,2] => 111000
[4,3,6,7,2,1,5] => 111000
[4,3,6,7,2,5,1] => 111000
[4,3,6,7,5,1,2] => 101010
[4,3,6,7,5,2,1] => 111010
[4,3,7,1,2,5,6] => 101000
[4,3,7,1,2,6,5] => 101010
[4,3,7,1,5,2,6] => 111000
[4,3,7,1,5,6,2] => 111000
[4,3,7,1,6,2,5] => 111000
[4,3,7,1,6,5,2] => 111010
[4,3,7,2,1,5,6] => 111000
[4,3,7,2,1,6,5] => 111010
[4,3,7,2,5,1,6] => 111000
[4,3,7,2,5,6,1] => 111000
[4,3,7,2,6,1,5] => 111000
[4,3,7,2,6,5,1] => 111010
[4,3,7,5,1,2,6] => 101010
[4,3,7,5,1,6,2] => 111010
[4,3,7,5,2,1,6] => 111010
[4,3,7,5,2,6,1] => 111010
[4,3,7,5,6,1,2] => 101010
[4,3,7,5,6,2,1] => 111010
[4,3,7,6,1,2,5] => 101001
[4,3,7,6,1,5,2] => 111001
[4,3,7,6,2,1,5] => 111001
[4,3,7,6,2,5,1] => 111001
[4,3,7,6,5,1,2] => 101011
[4,3,7,6,5,2,1] => 111011
[4,5,1,2,3,6,7] => 100000
[4,5,1,2,3,7,6] => 100001
[4,5,1,2,6,3,7] => 101000
[4,5,1,2,6,7,3] => 101000
[4,5,1,2,7,3,6] => 101000
[4,5,1,2,7,6,3] => 101001
[4,5,1,3,2,6,7] => 110000
[4,5,1,3,2,7,6] => 110001
[4,5,1,3,6,2,7] => 110000
[4,5,1,3,6,7,2] => 110000
[4,5,1,3,7,2,6] => 110000
[4,5,1,3,7,6,2] => 110001
[4,5,1,6,2,3,7] => 110000
[4,5,1,6,2,7,3] => 111000
[4,5,1,6,3,2,7] => 111000
[4,5,1,6,3,7,2] => 111000
[4,5,1,6,7,2,3] => 110000
[4,5,1,6,7,3,2] => 111000
[4,5,1,7,2,3,6] => 110000
[4,5,1,7,2,6,3] => 111000
[4,5,1,7,3,2,6] => 111000
[4,5,1,7,3,6,2] => 111000
[4,5,1,7,6,2,3] => 110001
[4,5,1,7,6,3,2] => 111001
[4,5,2,1,3,6,7] => 110000
[4,5,2,1,3,7,6] => 110001
[4,5,2,1,6,3,7] => 111000
[4,5,2,1,6,7,3] => 111000
[4,5,2,1,7,3,6] => 111000
[4,5,2,1,7,6,3] => 111001
[4,5,2,3,1,6,7] => 110000
[4,5,2,3,1,7,6] => 110001
[4,5,2,3,6,1,7] => 110000
[4,5,2,3,6,7,1] => 110000
[4,5,2,3,7,1,6] => 110000
[4,5,2,3,7,6,1] => 110001
[4,5,2,6,1,3,7] => 110000
[4,5,2,6,1,7,3] => 111000
[4,5,2,6,3,1,7] => 111000
[4,5,2,6,3,7,1] => 111000
[4,5,2,6,7,1,3] => 110000
[4,5,2,6,7,3,1] => 111000
[4,5,2,7,1,3,6] => 110000
[4,5,2,7,1,6,3] => 111000
[4,5,2,7,3,1,6] => 111000
[4,5,2,7,3,6,1] => 111000
[4,5,2,7,6,1,3] => 110001
[4,5,2,7,6,3,1] => 111001
[4,5,3,1,2,6,7] => 101000
[4,5,3,1,2,7,6] => 101001
[4,5,3,1,6,2,7] => 111000
[4,5,3,1,6,7,2] => 111000
[4,5,3,1,7,2,6] => 111000
[4,5,3,1,7,6,2] => 111001
[4,5,3,2,1,6,7] => 111000
[4,5,3,2,1,7,6] => 111001
[4,5,3,2,6,1,7] => 111000
[4,5,3,2,6,7,1] => 111000
[4,5,3,2,7,1,6] => 111000
[4,5,3,2,7,6,1] => 111001
[4,5,3,6,1,2,7] => 101000
[4,5,3,6,1,7,2] => 111000
[4,5,3,6,2,1,7] => 111000
[4,5,3,6,2,7,1] => 111000
[4,5,3,6,7,1,2] => 101000
[4,5,3,6,7,2,1] => 111000
[4,5,3,7,1,2,6] => 101000
[4,5,3,7,1,6,2] => 111000
[4,5,3,7,2,1,6] => 111000
[4,5,3,7,2,6,1] => 111000
[4,5,3,7,6,1,2] => 101001
[4,5,3,7,6,2,1] => 111001
[4,5,6,1,2,3,7] => 100000
[4,5,6,1,2,7,3] => 101000
[4,5,6,1,3,2,7] => 110000
[4,5,6,1,3,7,2] => 110000
[4,5,6,1,7,2,3] => 110000
[4,5,6,1,7,3,2] => 111000
[4,5,6,2,1,3,7] => 110000
[4,5,6,2,1,7,3] => 111000
[4,5,6,2,3,1,7] => 110000
[4,5,6,2,3,7,1] => 110000
[4,5,6,2,7,1,3] => 110000
[4,5,6,2,7,3,1] => 111000
[4,5,6,3,1,2,7] => 101000
[4,5,6,3,1,7,2] => 111000
[4,5,6,3,2,1,7] => 111000
[4,5,6,3,2,7,1] => 111000
[4,5,6,3,7,1,2] => 101000
[4,5,6,3,7,2,1] => 111000
[4,5,6,7,1,2,3] => 100000
[4,5,6,7,1,3,2] => 110000
[4,5,6,7,2,1,3] => 110000
[4,5,6,7,2,3,1] => 110000
[4,5,6,7,3,1,2] => 101000
[4,5,6,7,3,2,1] => 111000
[4,5,7,1,2,3,6] => 100000
[4,5,7,1,2,6,3] => 101000
[4,5,7,1,3,2,6] => 110000
[4,5,7,1,3,6,2] => 110000
[4,5,7,1,6,2,3] => 110000
[4,5,7,1,6,3,2] => 111000
[4,5,7,2,1,3,6] => 110000
[4,5,7,2,1,6,3] => 111000
[4,5,7,2,3,1,6] => 110000
[4,5,7,2,3,6,1] => 110000
[4,5,7,2,6,1,3] => 110000
[4,5,7,2,6,3,1] => 111000
[4,5,7,3,1,2,6] => 101000
[4,5,7,3,1,6,2] => 111000
[4,5,7,3,2,1,6] => 111000
[4,5,7,3,2,6,1] => 111000
[4,5,7,3,6,1,2] => 101000
[4,5,7,3,6,2,1] => 111000
[4,5,7,6,1,2,3] => 100001
[4,5,7,6,1,3,2] => 110001
[4,5,7,6,2,1,3] => 110001
[4,5,7,6,2,3,1] => 110001
[4,5,7,6,3,1,2] => 101001
[4,5,7,6,3,2,1] => 111001
[4,6,1,2,3,5,7] => 100000
[4,6,1,2,3,7,5] => 100010
[4,6,1,2,5,3,7] => 101000
[4,6,1,2,5,7,3] => 101000
[4,6,1,2,7,3,5] => 101000
[4,6,1,2,7,5,3] => 101010
[4,6,1,3,2,5,7] => 110000
[4,6,1,3,2,7,5] => 110010
[4,6,1,3,5,2,7] => 110000
[4,6,1,3,5,7,2] => 110000
[4,6,1,3,7,2,5] => 110000
[4,6,1,3,7,5,2] => 110010
[4,6,1,5,2,3,7] => 110000
[4,6,1,5,2,7,3] => 111000
[4,6,1,5,3,2,7] => 111000
[4,6,1,5,3,7,2] => 111000
[4,6,1,5,7,2,3] => 110000
[4,6,1,5,7,3,2] => 111000
[4,6,1,7,2,3,5] => 110000
[4,6,1,7,2,5,3] => 111000
[4,6,1,7,3,2,5] => 111000
[4,6,1,7,3,5,2] => 111000
[4,6,1,7,5,2,3] => 110010
[4,6,1,7,5,3,2] => 111010
[4,6,2,1,3,5,7] => 110000
[4,6,2,1,3,7,5] => 110010
[4,6,2,1,5,3,7] => 111000
[4,6,2,1,5,7,3] => 111000
[4,6,2,1,7,3,5] => 111000
[4,6,2,1,7,5,3] => 111010
[4,6,2,3,1,5,7] => 110000
[4,6,2,3,1,7,5] => 110010
[4,6,2,3,5,1,7] => 110000
[4,6,2,3,5,7,1] => 110000
[4,6,2,3,7,1,5] => 110000
[4,6,2,3,7,5,1] => 110010
[4,6,2,5,1,3,7] => 110000
[4,6,2,5,1,7,3] => 111000
[4,6,2,5,3,1,7] => 111000
[4,6,2,5,3,7,1] => 111000
[4,6,2,5,7,1,3] => 110000
[4,6,2,5,7,3,1] => 111000
[4,6,2,7,1,3,5] => 110000
[4,6,2,7,1,5,3] => 111000
[4,6,2,7,3,1,5] => 111000
[4,6,2,7,3,5,1] => 111000
[4,6,2,7,5,1,3] => 110010
[4,6,2,7,5,3,1] => 111010
[4,6,3,1,2,5,7] => 101000
[4,6,3,1,2,7,5] => 101010
[4,6,3,1,5,2,7] => 111000
[4,6,3,1,5,7,2] => 111000
[4,6,3,1,7,2,5] => 111000
[4,6,3,1,7,5,2] => 111010
[4,6,3,2,1,5,7] => 111000
[4,6,3,2,1,7,5] => 111010
[4,6,3,2,5,1,7] => 111000
[4,6,3,2,5,7,1] => 111000
[4,6,3,2,7,1,5] => 111000
[4,6,3,2,7,5,1] => 111010
[4,6,3,5,1,2,7] => 101000
[4,6,3,5,1,7,2] => 111000
[4,6,3,5,2,1,7] => 111000
[4,6,3,5,2,7,1] => 111000
[4,6,3,5,7,1,2] => 101000
[4,6,3,5,7,2,1] => 111000
[4,6,3,7,1,2,5] => 101000
[4,6,3,7,1,5,2] => 111000
[4,6,3,7,2,1,5] => 111000
[4,6,3,7,2,5,1] => 111000
[4,6,3,7,5,1,2] => 101010
[4,6,3,7,5,2,1] => 111010
[4,6,5,1,2,3,7] => 100010
[4,6,5,1,2,7,3] => 101010
[4,6,5,1,3,2,7] => 110010
[4,6,5,1,3,7,2] => 110010
[4,6,5,1,7,2,3] => 110010
[4,6,5,1,7,3,2] => 111010
[4,6,5,2,1,3,7] => 110010
[4,6,5,2,1,7,3] => 111010
[4,6,5,2,3,1,7] => 110010
[4,6,5,2,3,7,1] => 110010
[4,6,5,2,7,1,3] => 110010
[4,6,5,2,7,3,1] => 111010
[4,6,5,3,1,2,7] => 101010
[4,6,5,3,1,7,2] => 111010
[4,6,5,3,2,1,7] => 111010
[4,6,5,3,2,7,1] => 111010
[4,6,5,3,7,1,2] => 101010
[4,6,5,3,7,2,1] => 111010
[4,6,5,7,1,2,3] => 100010
[4,6,5,7,1,3,2] => 110010
[4,6,5,7,2,1,3] => 110010
[4,6,5,7,2,3,1] => 110010
[4,6,5,7,3,1,2] => 101010
[4,6,5,7,3,2,1] => 111010
[4,6,7,1,2,3,5] => 100000
[4,6,7,1,2,5,3] => 101000
[4,6,7,1,3,2,5] => 110000
[4,6,7,1,3,5,2] => 110000
[4,6,7,1,5,2,3] => 110000
[4,6,7,1,5,3,2] => 111000
[4,6,7,2,1,3,5] => 110000
[4,6,7,2,1,5,3] => 111000
[4,6,7,2,3,1,5] => 110000
[4,6,7,2,3,5,1] => 110000
[4,6,7,2,5,1,3] => 110000
[4,6,7,2,5,3,1] => 111000
[4,6,7,3,1,2,5] => 101000
[4,6,7,3,1,5,2] => 111000
[4,6,7,3,2,1,5] => 111000
[4,6,7,3,2,5,1] => 111000
[4,6,7,3,5,1,2] => 101000
[4,6,7,3,5,2,1] => 111000
[4,6,7,5,1,2,3] => 100010
[4,6,7,5,1,3,2] => 110010
[4,6,7,5,2,1,3] => 110010
[4,6,7,5,2,3,1] => 110010
[4,6,7,5,3,1,2] => 101010
[4,6,7,5,3,2,1] => 111010
[4,7,1,2,3,5,6] => 100000
[4,7,1,2,3,6,5] => 100010
[4,7,1,2,5,3,6] => 101000
[4,7,1,2,5,6,3] => 101000
[4,7,1,2,6,3,5] => 101000
[4,7,1,2,6,5,3] => 101010
[4,7,1,3,2,5,6] => 110000
[4,7,1,3,2,6,5] => 110010
[4,7,1,3,5,2,6] => 110000
[4,7,1,3,5,6,2] => 110000
[4,7,1,3,6,2,5] => 110000
[4,7,1,3,6,5,2] => 110010
[4,7,1,5,2,3,6] => 110000
[4,7,1,5,2,6,3] => 111000
[4,7,1,5,3,2,6] => 111000
[4,7,1,5,3,6,2] => 111000
[4,7,1,5,6,2,3] => 110000
[4,7,1,5,6,3,2] => 111000
[4,7,1,6,2,3,5] => 110000
[4,7,1,6,2,5,3] => 111000
[4,7,1,6,3,2,5] => 111000
[4,7,1,6,3,5,2] => 111000
[4,7,1,6,5,2,3] => 110010
[4,7,1,6,5,3,2] => 111010
[4,7,2,1,3,5,6] => 110000
[4,7,2,1,3,6,5] => 110010
[4,7,2,1,5,3,6] => 111000
[4,7,2,1,5,6,3] => 111000
[4,7,2,1,6,3,5] => 111000
[4,7,2,1,6,5,3] => 111010
[4,7,2,3,1,5,6] => 110000
[4,7,2,3,1,6,5] => 110010
[4,7,2,3,5,1,6] => 110000
[4,7,2,3,5,6,1] => 110000
[4,7,2,3,6,1,5] => 110000
[4,7,2,3,6,5,1] => 110010
[4,7,2,5,1,3,6] => 110000
[4,7,2,5,1,6,3] => 111000
[4,7,2,5,3,1,6] => 111000
[4,7,2,5,3,6,1] => 111000
[4,7,2,5,6,1,3] => 110000
[4,7,2,5,6,3,1] => 111000
[4,7,2,6,1,3,5] => 110000
[4,7,2,6,1,5,3] => 111000
[4,7,2,6,3,1,5] => 111000
[4,7,2,6,3,5,1] => 111000
[4,7,2,6,5,1,3] => 110010
[4,7,2,6,5,3,1] => 111010
[4,7,3,1,2,5,6] => 101000
[4,7,3,1,2,6,5] => 101010
[4,7,3,1,5,2,6] => 111000
[4,7,3,1,5,6,2] => 111000
[4,7,3,1,6,2,5] => 111000
[4,7,3,1,6,5,2] => 111010
[4,7,3,2,1,5,6] => 111000
[4,7,3,2,1,6,5] => 111010
[4,7,3,2,5,1,6] => 111000
[4,7,3,2,5,6,1] => 111000
[4,7,3,2,6,1,5] => 111000
[4,7,3,2,6,5,1] => 111010
[4,7,3,5,1,2,6] => 101000
[4,7,3,5,1,6,2] => 111000
[4,7,3,5,2,1,6] => 111000
[4,7,3,5,2,6,1] => 111000
[4,7,3,5,6,1,2] => 101000
[4,7,3,5,6,2,1] => 111000
[4,7,3,6,1,2,5] => 101000
[4,7,3,6,1,5,2] => 111000
[4,7,3,6,2,1,5] => 111000
[4,7,3,6,2,5,1] => 111000
[4,7,3,6,5,1,2] => 101010
[4,7,3,6,5,2,1] => 111010
[4,7,5,1,2,3,6] => 100010
[4,7,5,1,2,6,3] => 101010
[4,7,5,1,3,2,6] => 110010
[4,7,5,1,3,6,2] => 110010
[4,7,5,1,6,2,3] => 110010
[4,7,5,1,6,3,2] => 111010
[4,7,5,2,1,3,6] => 110010
[4,7,5,2,1,6,3] => 111010
[4,7,5,2,3,1,6] => 110010
[4,7,5,2,3,6,1] => 110010
[4,7,5,2,6,1,3] => 110010
[4,7,5,2,6,3,1] => 111010
[4,7,5,3,1,2,6] => 101010
[4,7,5,3,1,6,2] => 111010
[4,7,5,3,2,1,6] => 111010
[4,7,5,3,2,6,1] => 111010
[4,7,5,3,6,1,2] => 101010
[4,7,5,3,6,2,1] => 111010
[4,7,5,6,1,2,3] => 100010
[4,7,5,6,1,3,2] => 110010
[4,7,5,6,2,1,3] => 110010
[4,7,5,6,2,3,1] => 110010
[4,7,5,6,3,1,2] => 101010
[4,7,5,6,3,2,1] => 111010
[4,7,6,1,2,3,5] => 100001
[4,7,6,1,2,5,3] => 101001
[4,7,6,1,3,2,5] => 110001
[4,7,6,1,3,5,2] => 110001
[4,7,6,1,5,2,3] => 110001
[4,7,6,1,5,3,2] => 111001
[4,7,6,2,1,3,5] => 110001
[4,7,6,2,1,5,3] => 111001
[4,7,6,2,3,1,5] => 110001
[4,7,6,2,3,5,1] => 110001
[4,7,6,2,5,1,3] => 110001
[4,7,6,2,5,3,1] => 111001
[4,7,6,3,1,2,5] => 101001
[4,7,6,3,1,5,2] => 111001
[4,7,6,3,2,1,5] => 111001
[4,7,6,3,2,5,1] => 111001
[4,7,6,3,5,1,2] => 101001
[4,7,6,3,5,2,1] => 111001
[4,7,6,5,1,2,3] => 100011
[4,7,6,5,1,3,2] => 110011
[4,7,6,5,2,1,3] => 110011
[4,7,6,5,2,3,1] => 110011
[4,7,6,5,3,1,2] => 101011
[4,7,6,5,3,2,1] => 111011
[5,1,2,3,4,6,7] => 100000
[5,1,2,3,4,7,6] => 100001
[5,1,2,3,6,4,7] => 100100
[5,1,2,3,6,7,4] => 100100
[5,1,2,3,7,4,6] => 100100
[5,1,2,3,7,6,4] => 100101
[5,1,2,4,3,6,7] => 101000
[5,1,2,4,3,7,6] => 101001
[5,1,2,4,6,3,7] => 101000
[5,1,2,4,6,7,3] => 101000
[5,1,2,4,7,3,6] => 101000
[5,1,2,4,7,6,3] => 101001
[5,1,2,6,3,4,7] => 101000
[5,1,2,6,3,7,4] => 101100
[5,1,2,6,4,3,7] => 101100
[5,1,2,6,4,7,3] => 101100
[5,1,2,6,7,3,4] => 101000
[5,1,2,6,7,4,3] => 101100
[5,1,2,7,3,4,6] => 101000
[5,1,2,7,3,6,4] => 101100
[5,1,2,7,4,3,6] => 101100
[5,1,2,7,4,6,3] => 101100
[5,1,2,7,6,3,4] => 101001
[5,1,2,7,6,4,3] => 101101
[5,1,3,2,4,6,7] => 110000
[5,1,3,2,4,7,6] => 110001
[5,1,3,2,6,4,7] => 110100
[5,1,3,2,6,7,4] => 110100
[5,1,3,2,7,4,6] => 110100
[5,1,3,2,7,6,4] => 110101
[5,1,3,4,2,6,7] => 110000
[5,1,3,4,2,7,6] => 110001
[5,1,3,4,6,2,7] => 110000
[5,1,3,4,6,7,2] => 110000
[5,1,3,4,7,2,6] => 110000
[5,1,3,4,7,6,2] => 110001
[5,1,3,6,2,4,7] => 110000
[5,1,3,6,2,7,4] => 110100
[5,1,3,6,4,2,7] => 110100
[5,1,3,6,4,7,2] => 110100
[5,1,3,6,7,2,4] => 110000
[5,1,3,6,7,4,2] => 110100
[5,1,3,7,2,4,6] => 110000
[5,1,3,7,2,6,4] => 110100
[5,1,3,7,4,2,6] => 110100
[5,1,3,7,4,6,2] => 110100
[5,1,3,7,6,2,4] => 110001
[5,1,3,7,6,4,2] => 110101
[5,1,4,2,3,6,7] => 110000
[5,1,4,2,3,7,6] => 110001
[5,1,4,2,6,3,7] => 111000
[5,1,4,2,6,7,3] => 111000
[5,1,4,2,7,3,6] => 111000
[5,1,4,2,7,6,3] => 111001
[5,1,4,3,2,6,7] => 111000
[5,1,4,3,2,7,6] => 111001
[5,1,4,3,6,2,7] => 111000
[5,1,4,3,6,7,2] => 111000
[5,1,4,3,7,2,6] => 111000
[5,1,4,3,7,6,2] => 111001
[5,1,4,6,2,3,7] => 110000
[5,1,4,6,2,7,3] => 111000
[5,1,4,6,3,2,7] => 111000
[5,1,4,6,3,7,2] => 111000
[5,1,4,6,7,2,3] => 110000
[5,1,4,6,7,3,2] => 111000
[5,1,4,7,2,3,6] => 110000
[5,1,4,7,2,6,3] => 111000
[5,1,4,7,3,2,6] => 111000
[5,1,4,7,3,6,2] => 111000
[5,1,4,7,6,2,3] => 110001
[5,1,4,7,6,3,2] => 111001
[5,1,6,2,3,4,7] => 110000
[5,1,6,2,3,7,4] => 110100
[5,1,6,2,4,3,7] => 111000
[5,1,6,2,4,7,3] => 111000
[5,1,6,2,7,3,4] => 111000
[5,1,6,2,7,4,3] => 111100
[5,1,6,3,2,4,7] => 111000
[5,1,6,3,2,7,4] => 111100
[5,1,6,3,4,2,7] => 111000
[5,1,6,3,4,7,2] => 111000
[5,1,6,3,7,2,4] => 111000
[5,1,6,3,7,4,2] => 111100
[5,1,6,4,2,3,7] => 110100
[5,1,6,4,2,7,3] => 111100
[5,1,6,4,3,2,7] => 111100
[5,1,6,4,3,7,2] => 111100
[5,1,6,4,7,2,3] => 110100
[5,1,6,4,7,3,2] => 111100
[5,1,6,7,2,3,4] => 110000
[5,1,6,7,2,4,3] => 111000
[5,1,6,7,3,2,4] => 111000
[5,1,6,7,3,4,2] => 111000
[5,1,6,7,4,2,3] => 110100
[5,1,6,7,4,3,2] => 111100
[5,1,7,2,3,4,6] => 110000
[5,1,7,2,3,6,4] => 110100
[5,1,7,2,4,3,6] => 111000
[5,1,7,2,4,6,3] => 111000
[5,1,7,2,6,3,4] => 111000
[5,1,7,2,6,4,3] => 111100
[5,1,7,3,2,4,6] => 111000
[5,1,7,3,2,6,4] => 111100
[5,1,7,3,4,2,6] => 111000
[5,1,7,3,4,6,2] => 111000
[5,1,7,3,6,2,4] => 111000
[5,1,7,3,6,4,2] => 111100
[5,1,7,4,2,3,6] => 110100
[5,1,7,4,2,6,3] => 111100
[5,1,7,4,3,2,6] => 111100
[5,1,7,4,3,6,2] => 111100
[5,1,7,4,6,2,3] => 110100
[5,1,7,4,6,3,2] => 111100
[5,1,7,6,2,3,4] => 110001
[5,1,7,6,2,4,3] => 111001
[5,1,7,6,3,2,4] => 111001
[5,1,7,6,3,4,2] => 111001
[5,1,7,6,4,2,3] => 110101
[5,1,7,6,4,3,2] => 111101
[5,2,1,3,4,6,7] => 110000
[5,2,1,3,4,7,6] => 110001
[5,2,1,3,6,4,7] => 110100
[5,2,1,3,6,7,4] => 110100
[5,2,1,3,7,4,6] => 110100
[5,2,1,3,7,6,4] => 110101
[5,2,1,4,3,6,7] => 111000
[5,2,1,4,3,7,6] => 111001
[5,2,1,4,6,3,7] => 111000
[5,2,1,4,6,7,3] => 111000
[5,2,1,4,7,3,6] => 111000
[5,2,1,4,7,6,3] => 111001
[5,2,1,6,3,4,7] => 111000
[5,2,1,6,3,7,4] => 111100
[5,2,1,6,4,3,7] => 111100
[5,2,1,6,4,7,3] => 111100
[5,2,1,6,7,3,4] => 111000
[5,2,1,6,7,4,3] => 111100
[5,2,1,7,3,4,6] => 111000
[5,2,1,7,3,6,4] => 111100
[5,2,1,7,4,3,6] => 111100
[5,2,1,7,4,6,3] => 111100
[5,2,1,7,6,3,4] => 111001
[5,2,1,7,6,4,3] => 111101
[5,2,3,1,4,6,7] => 110000
[5,2,3,1,4,7,6] => 110001
[5,2,3,1,6,4,7] => 110100
[5,2,3,1,6,7,4] => 110100
[5,2,3,1,7,4,6] => 110100
[5,2,3,1,7,6,4] => 110101
[5,2,3,4,1,6,7] => 110000
[5,2,3,4,1,7,6] => 110001
[5,2,3,4,6,1,7] => 110000
[5,2,3,4,6,7,1] => 110000
[5,2,3,4,7,1,6] => 110000
[5,2,3,4,7,6,1] => 110001
[5,2,3,6,1,4,7] => 110000
[5,2,3,6,1,7,4] => 110100
[5,2,3,6,4,1,7] => 110100
[5,2,3,6,4,7,1] => 110100
[5,2,3,6,7,1,4] => 110000
[5,2,3,6,7,4,1] => 110100
[5,2,3,7,1,4,6] => 110000
[5,2,3,7,1,6,4] => 110100
[5,2,3,7,4,1,6] => 110100
[5,2,3,7,4,6,1] => 110100
[5,2,3,7,6,1,4] => 110001
[5,2,3,7,6,4,1] => 110101
[5,2,4,1,3,6,7] => 110000
[5,2,4,1,3,7,6] => 110001
[5,2,4,1,6,3,7] => 111000
[5,2,4,1,6,7,3] => 111000
[5,2,4,1,7,3,6] => 111000
[5,2,4,1,7,6,3] => 111001
[5,2,4,3,1,6,7] => 111000
[5,2,4,3,1,7,6] => 111001
[5,2,4,3,6,1,7] => 111000
[5,2,4,3,6,7,1] => 111000
[5,2,4,3,7,1,6] => 111000
[5,2,4,3,7,6,1] => 111001
[5,2,4,6,1,3,7] => 110000
[5,2,4,6,1,7,3] => 111000
[5,2,4,6,3,1,7] => 111000
[5,2,4,6,3,7,1] => 111000
[5,2,4,6,7,1,3] => 110000
[5,2,4,6,7,3,1] => 111000
[5,2,4,7,1,3,6] => 110000
[5,2,4,7,1,6,3] => 111000
[5,2,4,7,3,1,6] => 111000
[5,2,4,7,3,6,1] => 111000
[5,2,4,7,6,1,3] => 110001
[5,2,4,7,6,3,1] => 111001
[5,2,6,1,3,4,7] => 110000
[5,2,6,1,3,7,4] => 110100
[5,2,6,1,4,3,7] => 111000
[5,2,6,1,4,7,3] => 111000
[5,2,6,1,7,3,4] => 111000
[5,2,6,1,7,4,3] => 111100
[5,2,6,3,1,4,7] => 111000
[5,2,6,3,1,7,4] => 111100
[5,2,6,3,4,1,7] => 111000
[5,2,6,3,4,7,1] => 111000
[5,2,6,3,7,1,4] => 111000
[5,2,6,3,7,4,1] => 111100
[5,2,6,4,1,3,7] => 110100
[5,2,6,4,1,7,3] => 111100
[5,2,6,4,3,1,7] => 111100
[5,2,6,4,3,7,1] => 111100
[5,2,6,4,7,1,3] => 110100
[5,2,6,4,7,3,1] => 111100
[5,2,6,7,1,3,4] => 110000
[5,2,6,7,1,4,3] => 111000
[5,2,6,7,3,1,4] => 111000
[5,2,6,7,3,4,1] => 111000
[5,2,6,7,4,1,3] => 110100
[5,2,6,7,4,3,1] => 111100
[5,2,7,1,3,4,6] => 110000
[5,2,7,1,3,6,4] => 110100
[5,2,7,1,4,3,6] => 111000
[5,2,7,1,4,6,3] => 111000
[5,2,7,1,6,3,4] => 111000
[5,2,7,1,6,4,3] => 111100
[5,2,7,3,1,4,6] => 111000
[5,2,7,3,1,6,4] => 111100
[5,2,7,3,4,1,6] => 111000
[5,2,7,3,4,6,1] => 111000
[5,2,7,3,6,1,4] => 111000
[5,2,7,3,6,4,1] => 111100
[5,2,7,4,1,3,6] => 110100
[5,2,7,4,1,6,3] => 111100
[5,2,7,4,3,1,6] => 111100
[5,2,7,4,3,6,1] => 111100
[5,2,7,4,6,1,3] => 110100
[5,2,7,4,6,3,1] => 111100
[5,2,7,6,1,3,4] => 110001
[5,2,7,6,1,4,3] => 111001
[5,2,7,6,3,1,4] => 111001
[5,2,7,6,3,4,1] => 111001
[5,2,7,6,4,1,3] => 110101
[5,2,7,6,4,3,1] => 111101
[5,3,1,2,4,6,7] => 101000
[5,3,1,2,4,7,6] => 101001
[5,3,1,2,6,4,7] => 101100
[5,3,1,2,6,7,4] => 101100
[5,3,1,2,7,4,6] => 101100
[5,3,1,2,7,6,4] => 101101
[5,3,1,4,2,6,7] => 111000
[5,3,1,4,2,7,6] => 111001
[5,3,1,4,6,2,7] => 111000
[5,3,1,4,6,7,2] => 111000
[5,3,1,4,7,2,6] => 111000
[5,3,1,4,7,6,2] => 111001
[5,3,1,6,2,4,7] => 111000
[5,3,1,6,2,7,4] => 111100
[5,3,1,6,4,2,7] => 111100
[5,3,1,6,4,7,2] => 111100
[5,3,1,6,7,2,4] => 111000
[5,3,1,6,7,4,2] => 111100
[5,3,1,7,2,4,6] => 111000
[5,3,1,7,2,6,4] => 111100
[5,3,1,7,4,2,6] => 111100
[5,3,1,7,4,6,2] => 111100
[5,3,1,7,6,2,4] => 111001
[5,3,1,7,6,4,2] => 111101
[5,3,2,1,4,6,7] => 111000
[5,3,2,1,4,7,6] => 111001
[5,3,2,1,6,4,7] => 111100
[5,3,2,1,6,7,4] => 111100
[5,3,2,1,7,4,6] => 111100
[5,3,2,1,7,6,4] => 111101
[5,3,2,4,1,6,7] => 111000
[5,3,2,4,1,7,6] => 111001
[5,3,2,4,6,1,7] => 111000
[5,3,2,4,6,7,1] => 111000
[5,3,2,4,7,1,6] => 111000
[5,3,2,4,7,6,1] => 111001
[5,3,2,6,1,4,7] => 111000
[5,3,2,6,1,7,4] => 111100
[5,3,2,6,4,1,7] => 111100
[5,3,2,6,4,7,1] => 111100
[5,3,2,6,7,1,4] => 111000
[5,3,2,6,7,4,1] => 111100
[5,3,2,7,1,4,6] => 111000
[5,3,2,7,1,6,4] => 111100
[5,3,2,7,4,1,6] => 111100
[5,3,2,7,4,6,1] => 111100
[5,3,2,7,6,1,4] => 111001
[5,3,2,7,6,4,1] => 111101
[5,3,4,1,2,6,7] => 101000
[5,3,4,1,2,7,6] => 101001
[5,3,4,1,6,2,7] => 111000
[5,3,4,1,6,7,2] => 111000
[5,3,4,1,7,2,6] => 111000
[5,3,4,1,7,6,2] => 111001
[5,3,4,2,1,6,7] => 111000
[5,3,4,2,1,7,6] => 111001
[5,3,4,2,6,1,7] => 111000
[5,3,4,2,6,7,1] => 111000
[5,3,4,2,7,1,6] => 111000
[5,3,4,2,7,6,1] => 111001
[5,3,4,6,1,2,7] => 101000
[5,3,4,6,1,7,2] => 111000
[5,3,4,6,2,1,7] => 111000
[5,3,4,6,2,7,1] => 111000
[5,3,4,6,7,1,2] => 101000
[5,3,4,6,7,2,1] => 111000
[5,3,4,7,1,2,6] => 101000
[5,3,4,7,1,6,2] => 111000
[5,3,4,7,2,1,6] => 111000
[5,3,4,7,2,6,1] => 111000
[5,3,4,7,6,1,2] => 101001
[5,3,4,7,6,2,1] => 111001
[5,3,6,1,2,4,7] => 101000
[5,3,6,1,2,7,4] => 101100
[5,3,6,1,4,2,7] => 111000
[5,3,6,1,4,7,2] => 111000
[5,3,6,1,7,2,4] => 111000
[5,3,6,1,7,4,2] => 111100
[5,3,6,2,1,4,7] => 111000
[5,3,6,2,1,7,4] => 111100
[5,3,6,2,4,1,7] => 111000
[5,3,6,2,4,7,1] => 111000
[5,3,6,2,7,1,4] => 111000
[5,3,6,2,7,4,1] => 111100
[5,3,6,4,1,2,7] => 101100
[5,3,6,4,1,7,2] => 111100
[5,3,6,4,2,1,7] => 111100
[5,3,6,4,2,7,1] => 111100
[5,3,6,4,7,1,2] => 101100
[5,3,6,4,7,2,1] => 111100
[5,3,6,7,1,2,4] => 101000
[5,3,6,7,1,4,2] => 111000
[5,3,6,7,2,1,4] => 111000
[5,3,6,7,2,4,1] => 111000
[5,3,6,7,4,1,2] => 101100
[5,3,6,7,4,2,1] => 111100
[5,3,7,1,2,4,6] => 101000
[5,3,7,1,2,6,4] => 101100
[5,3,7,1,4,2,6] => 111000
[5,3,7,1,4,6,2] => 111000
[5,3,7,1,6,2,4] => 111000
[5,3,7,1,6,4,2] => 111100
[5,3,7,2,1,4,6] => 111000
[5,3,7,2,1,6,4] => 111100
[5,3,7,2,4,1,6] => 111000
[5,3,7,2,4,6,1] => 111000
[5,3,7,2,6,1,4] => 111000
[5,3,7,2,6,4,1] => 111100
[5,3,7,4,1,2,6] => 101100
[5,3,7,4,1,6,2] => 111100
[5,3,7,4,2,1,6] => 111100
[5,3,7,4,2,6,1] => 111100
[5,3,7,4,6,1,2] => 101100
[5,3,7,4,6,2,1] => 111100
[5,3,7,6,1,2,4] => 101001
[5,3,7,6,1,4,2] => 111001
[5,3,7,6,2,1,4] => 111001
[5,3,7,6,2,4,1] => 111001
[5,3,7,6,4,1,2] => 101101
[5,3,7,6,4,2,1] => 111101
[5,4,1,2,3,6,7] => 100100
[5,4,1,2,3,7,6] => 100101
[5,4,1,2,6,3,7] => 101100
[5,4,1,2,6,7,3] => 101100
[5,4,1,2,7,3,6] => 101100
[5,4,1,2,7,6,3] => 101101
[5,4,1,3,2,6,7] => 110100
[5,4,1,3,2,7,6] => 110101
[5,4,1,3,6,2,7] => 110100
[5,4,1,3,6,7,2] => 110100
[5,4,1,3,7,2,6] => 110100
[5,4,1,3,7,6,2] => 110101
[5,4,1,6,2,3,7] => 110100
[5,4,1,6,2,7,3] => 111100
[5,4,1,6,3,2,7] => 111100
[5,4,1,6,3,7,2] => 111100
[5,4,1,6,7,2,3] => 110100
[5,4,1,6,7,3,2] => 111100
[5,4,1,7,2,3,6] => 110100
[5,4,1,7,2,6,3] => 111100
[5,4,1,7,3,2,6] => 111100
[5,4,1,7,3,6,2] => 111100
[5,4,1,7,6,2,3] => 110101
[5,4,1,7,6,3,2] => 111101
[5,4,2,1,3,6,7] => 110100
[5,4,2,1,3,7,6] => 110101
[5,4,2,1,6,3,7] => 111100
[5,4,2,1,6,7,3] => 111100
[5,4,2,1,7,3,6] => 111100
[5,4,2,1,7,6,3] => 111101
[5,4,2,3,1,6,7] => 110100
[5,4,2,3,1,7,6] => 110101
[5,4,2,3,6,1,7] => 110100
[5,4,2,3,6,7,1] => 110100
[5,4,2,3,7,1,6] => 110100
[5,4,2,3,7,6,1] => 110101
[5,4,2,6,1,3,7] => 110100
[5,4,2,6,1,7,3] => 111100
[5,4,2,6,3,1,7] => 111100
[5,4,2,6,3,7,1] => 111100
[5,4,2,6,7,1,3] => 110100
[5,4,2,6,7,3,1] => 111100
[5,4,2,7,1,3,6] => 110100
[5,4,2,7,1,6,3] => 111100
[5,4,2,7,3,1,6] => 111100
[5,4,2,7,3,6,1] => 111100
[5,4,2,7,6,1,3] => 110101
[5,4,2,7,6,3,1] => 111101
[5,4,3,1,2,6,7] => 101100
[5,4,3,1,2,7,6] => 101101
[5,4,3,1,6,2,7] => 111100
[5,4,3,1,6,7,2] => 111100
[5,4,3,1,7,2,6] => 111100
[5,4,3,1,7,6,2] => 111101
[5,4,3,2,1,6,7] => 111100
[5,4,3,2,1,7,6] => 111101
[5,4,3,2,6,1,7] => 111100
[5,4,3,2,6,7,1] => 111100
[5,4,3,2,7,1,6] => 111100
[5,4,3,2,7,6,1] => 111101
[5,4,3,6,1,2,7] => 101100
[5,4,3,6,1,7,2] => 111100
[5,4,3,6,2,1,7] => 111100
[5,4,3,6,2,7,1] => 111100
[5,4,3,6,7,1,2] => 101100
[5,4,3,6,7,2,1] => 111100
[5,4,3,7,1,2,6] => 101100
[5,4,3,7,1,6,2] => 111100
[5,4,3,7,2,1,6] => 111100
[5,4,3,7,2,6,1] => 111100
[5,4,3,7,6,1,2] => 101101
[5,4,3,7,6,2,1] => 111101
[5,4,6,1,2,3,7] => 100100
[5,4,6,1,2,7,3] => 101100
[5,4,6,1,3,2,7] => 110100
[5,4,6,1,3,7,2] => 110100
[5,4,6,1,7,2,3] => 110100
[5,4,6,1,7,3,2] => 111100
[5,4,6,2,1,3,7] => 110100
[5,4,6,2,1,7,3] => 111100
[5,4,6,2,3,1,7] => 110100
[5,4,6,2,3,7,1] => 110100
[5,4,6,2,7,1,3] => 110100
[5,4,6,2,7,3,1] => 111100
[5,4,6,3,1,2,7] => 101100
[5,4,6,3,1,7,2] => 111100
[5,4,6,3,2,1,7] => 111100
[5,4,6,3,2,7,1] => 111100
[5,4,6,3,7,1,2] => 101100
[5,4,6,3,7,2,1] => 111100
[5,4,6,7,1,2,3] => 100100
[5,4,6,7,1,3,2] => 110100
[5,4,6,7,2,1,3] => 110100
[5,4,6,7,2,3,1] => 110100
[5,4,6,7,3,1,2] => 101100
[5,4,6,7,3,2,1] => 111100
[5,4,7,1,2,3,6] => 100100
[5,4,7,1,2,6,3] => 101100
[5,4,7,1,3,2,6] => 110100
[5,4,7,1,3,6,2] => 110100
[5,4,7,1,6,2,3] => 110100
[5,4,7,1,6,3,2] => 111100
[5,4,7,2,1,3,6] => 110100
[5,4,7,2,1,6,3] => 111100
[5,4,7,2,3,1,6] => 110100
[5,4,7,2,3,6,1] => 110100
[5,4,7,2,6,1,3] => 110100
[5,4,7,2,6,3,1] => 111100
[5,4,7,3,1,2,6] => 101100
[5,4,7,3,1,6,2] => 111100
[5,4,7,3,2,1,6] => 111100
[5,4,7,3,2,6,1] => 111100
[5,4,7,3,6,1,2] => 101100
[5,4,7,3,6,2,1] => 111100
[5,4,7,6,1,2,3] => 100101
[5,4,7,6,1,3,2] => 110101
[5,4,7,6,2,1,3] => 110101
[5,4,7,6,2,3,1] => 110101
[5,4,7,6,3,1,2] => 101101
[5,4,7,6,3,2,1] => 111101
[5,6,1,2,3,4,7] => 100000
[5,6,1,2,3,7,4] => 100100
[5,6,1,2,4,3,7] => 101000
[5,6,1,2,4,7,3] => 101000
[5,6,1,2,7,3,4] => 101000
[5,6,1,2,7,4,3] => 101100
[5,6,1,3,2,4,7] => 110000
[5,6,1,3,2,7,4] => 110100
[5,6,1,3,4,2,7] => 110000
[5,6,1,3,4,7,2] => 110000
[5,6,1,3,7,2,4] => 110000
[5,6,1,3,7,4,2] => 110100
[5,6,1,4,2,3,7] => 110000
[5,6,1,4,2,7,3] => 111000
[5,6,1,4,3,2,7] => 111000
[5,6,1,4,3,7,2] => 111000
[5,6,1,4,7,2,3] => 110000
[5,6,1,4,7,3,2] => 111000
[5,6,1,7,2,3,4] => 110000
[5,6,1,7,2,4,3] => 111000
[5,6,1,7,3,2,4] => 111000
[5,6,1,7,3,4,2] => 111000
[5,6,1,7,4,2,3] => 110100
[5,6,1,7,4,3,2] => 111100
[5,6,2,1,3,4,7] => 110000
[5,6,2,1,3,7,4] => 110100
[5,6,2,1,4,3,7] => 111000
[5,6,2,1,4,7,3] => 111000
[5,6,2,1,7,3,4] => 111000
[5,6,2,1,7,4,3] => 111100
[5,6,2,3,1,4,7] => 110000
[5,6,2,3,1,7,4] => 110100
[5,6,2,3,4,1,7] => 110000
[5,6,2,3,4,7,1] => 110000
[5,6,2,3,7,1,4] => 110000
[5,6,2,3,7,4,1] => 110100
[5,6,2,4,1,3,7] => 110000
[5,6,2,4,1,7,3] => 111000
[5,6,2,4,3,1,7] => 111000
[5,6,2,4,3,7,1] => 111000
[5,6,2,4,7,1,3] => 110000
[5,6,2,4,7,3,1] => 111000
[5,6,2,7,1,3,4] => 110000
[5,6,2,7,1,4,3] => 111000
[5,6,2,7,3,1,4] => 111000
[5,6,2,7,3,4,1] => 111000
[5,6,2,7,4,1,3] => 110100
[5,6,2,7,4,3,1] => 111100
[5,6,3,1,2,4,7] => 101000
[5,6,3,1,2,7,4] => 101100
[5,6,3,1,4,2,7] => 111000
[5,6,3,1,4,7,2] => 111000
[5,6,3,1,7,2,4] => 111000
[5,6,3,1,7,4,2] => 111100
[5,6,3,2,1,4,7] => 111000
[5,6,3,2,1,7,4] => 111100
[5,6,3,2,4,1,7] => 111000
[5,6,3,2,4,7,1] => 111000
[5,6,3,2,7,1,4] => 111000
[5,6,3,2,7,4,1] => 111100
[5,6,3,4,1,2,7] => 101000
[5,6,3,4,1,7,2] => 111000
[5,6,3,4,2,1,7] => 111000
[5,6,3,4,2,7,1] => 111000
[5,6,3,4,7,1,2] => 101000
[5,6,3,4,7,2,1] => 111000
[5,6,3,7,1,2,4] => 101000
[5,6,3,7,1,4,2] => 111000
[5,6,3,7,2,1,4] => 111000
[5,6,3,7,2,4,1] => 111000
[5,6,3,7,4,1,2] => 101100
[5,6,3,7,4,2,1] => 111100
[5,6,4,1,2,3,7] => 100100
[5,6,4,1,2,7,3] => 101100
[5,6,4,1,3,2,7] => 110100
[5,6,4,1,3,7,2] => 110100
[5,6,4,1,7,2,3] => 110100
[5,6,4,1,7,3,2] => 111100
[5,6,4,2,1,3,7] => 110100
[5,6,4,2,1,7,3] => 111100
[5,6,4,2,3,1,7] => 110100
[5,6,4,2,3,7,1] => 110100
[5,6,4,2,7,1,3] => 110100
[5,6,4,2,7,3,1] => 111100
[5,6,4,3,1,2,7] => 101100
[5,6,4,3,1,7,2] => 111100
[5,6,4,3,2,1,7] => 111100
[5,6,4,3,2,7,1] => 111100
[5,6,4,3,7,1,2] => 101100
[5,6,4,3,7,2,1] => 111100
[5,6,4,7,1,2,3] => 100100
[5,6,4,7,1,3,2] => 110100
[5,6,4,7,2,1,3] => 110100
[5,6,4,7,2,3,1] => 110100
[5,6,4,7,3,1,2] => 101100
[5,6,4,7,3,2,1] => 111100
[5,6,7,1,2,3,4] => 100000
[5,6,7,1,2,4,3] => 101000
[5,6,7,1,3,2,4] => 110000
[5,6,7,1,3,4,2] => 110000
[5,6,7,1,4,2,3] => 110000
[5,6,7,1,4,3,2] => 111000
[5,6,7,2,1,3,4] => 110000
[5,6,7,2,1,4,3] => 111000
[5,6,7,2,3,1,4] => 110000
[5,6,7,2,3,4,1] => 110000
[5,6,7,2,4,1,3] => 110000
[5,6,7,2,4,3,1] => 111000
[5,6,7,3,1,2,4] => 101000
[5,6,7,3,1,4,2] => 111000
[5,6,7,3,2,1,4] => 111000
[5,6,7,3,2,4,1] => 111000
[5,6,7,3,4,1,2] => 101000
[5,6,7,3,4,2,1] => 111000
[5,6,7,4,1,2,3] => 100100
[5,6,7,4,1,3,2] => 110100
[5,6,7,4,2,1,3] => 110100
[5,6,7,4,2,3,1] => 110100
[5,6,7,4,3,1,2] => 101100
[5,6,7,4,3,2,1] => 111100
[5,7,1,2,3,4,6] => 100000
[5,7,1,2,3,6,4] => 100100
[5,7,1,2,4,3,6] => 101000
[5,7,1,2,4,6,3] => 101000
[5,7,1,2,6,3,4] => 101000
[5,7,1,2,6,4,3] => 101100
[5,7,1,3,2,4,6] => 110000
[5,7,1,3,2,6,4] => 110100
[5,7,1,3,4,2,6] => 110000
[5,7,1,3,4,6,2] => 110000
[5,7,1,3,6,2,4] => 110000
[5,7,1,3,6,4,2] => 110100
[5,7,1,4,2,3,6] => 110000
[5,7,1,4,2,6,3] => 111000
[5,7,1,4,3,2,6] => 111000
[5,7,1,4,3,6,2] => 111000
[5,7,1,4,6,2,3] => 110000
[5,7,1,4,6,3,2] => 111000
[5,7,1,6,2,3,4] => 110000
[5,7,1,6,2,4,3] => 111000
[5,7,1,6,3,2,4] => 111000
[5,7,1,6,3,4,2] => 111000
[5,7,1,6,4,2,3] => 110100
[5,7,1,6,4,3,2] => 111100
[5,7,2,1,3,4,6] => 110000
[5,7,2,1,3,6,4] => 110100
[5,7,2,1,4,3,6] => 111000
[5,7,2,1,4,6,3] => 111000
[5,7,2,1,6,3,4] => 111000
[5,7,2,1,6,4,3] => 111100
[5,7,2,3,1,4,6] => 110000
[5,7,2,3,1,6,4] => 110100
[5,7,2,3,4,1,6] => 110000
[5,7,2,3,4,6,1] => 110000
[5,7,2,3,6,1,4] => 110000
[5,7,2,3,6,4,1] => 110100
[5,7,2,4,1,3,6] => 110000
[5,7,2,4,1,6,3] => 111000
[5,7,2,4,3,1,6] => 111000
[5,7,2,4,3,6,1] => 111000
[5,7,2,4,6,1,3] => 110000
[5,7,2,4,6,3,1] => 111000
[5,7,2,6,1,3,4] => 110000
[5,7,2,6,1,4,3] => 111000
[5,7,2,6,3,1,4] => 111000
[5,7,2,6,3,4,1] => 111000
[5,7,2,6,4,1,3] => 110100
[5,7,2,6,4,3,1] => 111100
[5,7,3,1,2,4,6] => 101000
[5,7,3,1,2,6,4] => 101100
[5,7,3,1,4,2,6] => 111000
[5,7,3,1,4,6,2] => 111000
[5,7,3,1,6,2,4] => 111000
[5,7,3,1,6,4,2] => 111100
[5,7,3,2,1,4,6] => 111000
[5,7,3,2,1,6,4] => 111100
[5,7,3,2,4,1,6] => 111000
[5,7,3,2,4,6,1] => 111000
[5,7,3,2,6,1,4] => 111000
[5,7,3,2,6,4,1] => 111100
[5,7,3,4,1,2,6] => 101000
[5,7,3,4,1,6,2] => 111000
[5,7,3,4,2,1,6] => 111000
[5,7,3,4,2,6,1] => 111000
[5,7,3,4,6,1,2] => 101000
[5,7,3,4,6,2,1] => 111000
[5,7,3,6,1,2,4] => 101000
[5,7,3,6,1,4,2] => 111000
[5,7,3,6,2,1,4] => 111000
[5,7,3,6,2,4,1] => 111000
[5,7,3,6,4,1,2] => 101100
[5,7,3,6,4,2,1] => 111100
[5,7,4,1,2,3,6] => 100100
[5,7,4,1,2,6,3] => 101100
[5,7,4,1,3,2,6] => 110100
[5,7,4,1,3,6,2] => 110100
[5,7,4,1,6,2,3] => 110100
[5,7,4,1,6,3,2] => 111100
[5,7,4,2,1,3,6] => 110100
[5,7,4,2,1,6,3] => 111100
[5,7,4,2,3,1,6] => 110100
[5,7,4,2,3,6,1] => 110100
[5,7,4,2,6,1,3] => 110100
[5,7,4,2,6,3,1] => 111100
[5,7,4,3,1,2,6] => 101100
[5,7,4,3,1,6,2] => 111100
[5,7,4,3,2,1,6] => 111100
[5,7,4,3,2,6,1] => 111100
[5,7,4,3,6,1,2] => 101100
[5,7,4,3,6,2,1] => 111100
[5,7,4,6,1,2,3] => 100100
[5,7,4,6,1,3,2] => 110100
[5,7,4,6,2,1,3] => 110100
[5,7,4,6,2,3,1] => 110100
[5,7,4,6,3,1,2] => 101100
[5,7,4,6,3,2,1] => 111100
[5,7,6,1,2,3,4] => 100001
[5,7,6,1,2,4,3] => 101001
[5,7,6,1,3,2,4] => 110001
[5,7,6,1,3,4,2] => 110001
[5,7,6,1,4,2,3] => 110001
[5,7,6,1,4,3,2] => 111001
[5,7,6,2,1,3,4] => 110001
[5,7,6,2,1,4,3] => 111001
[5,7,6,2,3,1,4] => 110001
[5,7,6,2,3,4,1] => 110001
[5,7,6,2,4,1,3] => 110001
[5,7,6,2,4,3,1] => 111001
[5,7,6,3,1,2,4] => 101001
[5,7,6,3,1,4,2] => 111001
[5,7,6,3,2,1,4] => 111001
[5,7,6,3,2,4,1] => 111001
[5,7,6,3,4,1,2] => 101001
[5,7,6,3,4,2,1] => 111001
[5,7,6,4,1,2,3] => 100101
[5,7,6,4,1,3,2] => 110101
[5,7,6,4,2,1,3] => 110101
[5,7,6,4,2,3,1] => 110101
[5,7,6,4,3,1,2] => 101101
[5,7,6,4,3,2,1] => 111101
[6,1,2,3,4,5,7] => 100000
[6,1,2,3,4,7,5] => 100010
[6,1,2,3,5,4,7] => 100100
[6,1,2,3,5,7,4] => 100100
[6,1,2,3,7,4,5] => 100100
[6,1,2,3,7,5,4] => 100110
[6,1,2,4,3,5,7] => 101000
[6,1,2,4,3,7,5] => 101010
[6,1,2,4,5,3,7] => 101000
[6,1,2,4,5,7,3] => 101000
[6,1,2,4,7,3,5] => 101000
[6,1,2,4,7,5,3] => 101010
[6,1,2,5,3,4,7] => 101000
[6,1,2,5,3,7,4] => 101100
[6,1,2,5,4,3,7] => 101100
[6,1,2,5,4,7,3] => 101100
[6,1,2,5,7,3,4] => 101000
[6,1,2,5,7,4,3] => 101100
[6,1,2,7,3,4,5] => 101000
[6,1,2,7,3,5,4] => 101100
[6,1,2,7,4,3,5] => 101100
[6,1,2,7,4,5,3] => 101100
[6,1,2,7,5,3,4] => 101010
[6,1,2,7,5,4,3] => 101110
[6,1,3,2,4,5,7] => 110000
[6,1,3,2,4,7,5] => 110010
[6,1,3,2,5,4,7] => 110100
[6,1,3,2,5,7,4] => 110100
[6,1,3,2,7,4,5] => 110100
[6,1,3,2,7,5,4] => 110110
[6,1,3,4,2,5,7] => 110000
[6,1,3,4,2,7,5] => 110010
[6,1,3,4,5,2,7] => 110000
[6,1,3,4,5,7,2] => 110000
[6,1,3,4,7,2,5] => 110000
[6,1,3,4,7,5,2] => 110010
[6,1,3,5,2,4,7] => 110000
[6,1,3,5,2,7,4] => 110100
[6,1,3,5,4,2,7] => 110100
[6,1,3,5,4,7,2]