Fork me on GitHub
#code-reviews
<
2018-12-03
>
timgilbert23:12:52

Seems pretty idiomatic to me. One thing I noticed is you could probably use (reduce +) in place of (reduce #(map + %1 %2))

jaihindhreddy-duplicate16:12:20

I want (reduce #(map + % %2) [[1 2] [1 2] [3 5] [2 6]])

jaihindhreddy-duplicate16:12:45

(reduce + [[1 2] [1 2] [3 5] [2 6]]) doesn't work here.

timgilbert23:12:27

...and I have a hunch that you could find something a little simpler than (filter #(apply = %)), though I can't think of it offhand. (Using apply like this is a faint code smell to me personally, though it certainly has its place)

jaihindhreddy-duplicate16:12:02

Thanks a lot for your insights.