This code:
validate :: Matrix-> Bool
validate x: [] = length x
validate x: xs = (length x == lenght.head $ xs) == (validate tail xs)
produces this error:
Parse error in pattern: validate
Why?
My aim is to return true if the matrix is in the correct patterns, ie the number of columns in all the rows are equal, or vice versa.