Re:Ask HN: Why Python over Ruby?
by seanodonnell on Wednesday July 01, 2009 @07:28PM
(#683562)
len(list) is actually a shortcut for calling list.__len__() , any object that implements the __len__ method is therefore compatible with it. So in practice, len is in fact a method call. Almost every python function that operates on objects is just a similar shorthand.
[ Parent
| on HN ]
There are no comments on this comment yet.