Applicative permutation to generate knight moves
Using pattern matching you can write:

invert 1 = 2
invert 2 = 1
invert n = 0 -- Error would be better in my opinion




You can inline 6 and 2 instead of taking them from a single item list.