[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: Newbie question on pairs and ipairs
- From: Asko Kauppi <asko.kauppi@...>
- Date: Thu, 16 Dec 2004 10:06:01 +0200
Can you live with this:
for k,v in pairs(tbl) do
if type(k)~="number" then
16.12.2004 kello 07:59, Glenn Edgar kirjoitti:
The source code indicates that a lua table consists of two parts, an
part and a hash table part. It also appears that ipairs iterates over
array part and pairs iterates over both the array and hash table part.
If my understanding is correct, I would like to ask the following
What is the best way to iterate over the keys that are only in that
part of the table?
Thanks for your help.