Removed Data.Array import.
Added missing type declaration to maxLength.
Removed unused sides code.
Whitespace cleanup.
Pre-multiply by m.
More point-free style in solution.