7 Mar
2007
7 Mar
'07
12:27 a.m.
sum . IntMap.elems . IntMap.IntersectionWith (\x y -> x*y) queryVector rationalProjection
Composition with (.) builds a function, but you eventually want an Int, so we can't just use (.), but we can come pretty close. (sum . IntMap.elems . IntMap.IntersectionWith (\x y -> x*y) queryVector) rationalProjection