Comment

Comment by thomie

Nice, but don't compute the length of a list if you don't have to.

(not . null) instead of (\x -> length x > 1) is shorter, and works on infinite lists also.

Edit: well, in case you would test for x>0.

parent thomie 16 years ago

No comments yet

Be the first to share your thoughts.

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton