[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: PiL 1
- From: Alexander Gladysh <agladysh@...>
- Date: Thu, 13 Oct 2011 03:58:52 +0400
On Wed, Oct 12, 2011 at 18:25, Petite Abeille <firstname.lastname@example.org> wrote:
> On Oct 12, 2011, at 2:58 PM, Alexander Gladysh wrote:
>> This does not means that one should use it.
> Why not? What's wrong with string.len?
>>> The length operator is new (in 5.1):
>> Why do you mention it?
> It applies to string as well:
> ( 'hello world' ):len() == #( 'hello world' )
And should be used instead of len(), yes.
But, OK, that counts as house rules, probably. (Can't imagine why
anyone would use len() nowadays, but that's just me.)
Still, have table.getn, table.foreach to show. :)