Re: Is it necessary to kill ipairs()?
[
Date Prev][
Date Next][
Thread Prev][
Thread Next]
[
Date Index]
[
Thread Index]
- Subject: Re: Is it necessary to kill ipairs()?
- From: Klaus Ripke <paul-lua@...>
- Date: 2010年5月22日 14:56:32 +0200
On Sat, May 22, 2010 at 03:42:23PM +0300, M Joonas Pihlaja wrote:
> > Without ipairs(), how do I code this convenient (and clear) idiom:
> >
> > --
> >
> > for _,v in ipairs{'lumpi','ist','mein',hund'} do
> > print(v)
> > end
>
> Using pairs().
>
> for _,v in pairs{'lumpi','ist','mein',hund'} do
> print(v)
> end
this might as well print Yoda-ish "mein hund lumpi ist".
("my dog lumpi is")