lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


Jan-Pieter Jacobs wrote:
> Actually the parentheses are not needed here, as there is no conflict in
order
> of operations:
> 
> example[1][3] = 5

Geoff Leyland wrote:
> $ lua
> Lua 5.1.5  Copyright (C) 1994-2012 Lua.org, PUC-Rio
> > example={{"Red",1,2},{"Green",3,4}}
> > example[1][3] = 5
> > print(example[1][3])
> 5

That works perfectly. Thanks, both, for replying so quickly (I had a feeling
it was going to be easier than I was making it!).

Best wishes,
Iain