How do I get the length of a sequence? Is there some generic way to
find the number of elements in something that might be list, map, vector
or lazy?
There must be some sort of built in function, or an idiom
Thanks
P
user=> (doc count)
-------------------------
clojure.core/count
([coll])
Returns the number of items in the collection. (count nil) returns
0. Also works on strings, arrays, and Java Collections and Maps
Note how the name and docs both cleverly avoid use of the words "size"
or "length", to help the function remain undiscovered by searches
through the source code and by uses of find-doc.
--Chouser
I think that since a patch was requested, you're welcome to send in
your CA [1], create and issue [2] and attach your patch. Otherwise
this is likely to get lost in the flood that is this discussion group.
[1] http://clojure.org/contributing
[2] http://code.google.com/p/clojure/issues
--Chouser