Make ArrayType comparable

Following
https://github.com/facebook/presto/issues/1816

A = B if they have the same cardinality and every element in A is equal to the corresponding element in B
A < B if
for some 1 <= k <= min(cardinality(A), cardinality(B)), A[i] = B[i] for every i < k and A[k] < B[k]
or, for every 1 <= i <= cardinality(A), A[i] = B[i] and cardinality(A) < cardinality(B)
@cberner for combining these hashes, do you think sum could be a possible way? Or do you have other suggestions?