Table.unpack: Difference between revisions
From GiderosMobile
Created page with "__NOTOC__ '''Available since:''' Gideros 2022.3<br/> '''Class:''' table<br/> === Description === Returns all elements from the given list as a tuple. <source lang="lua">..." |
m Text replacement - "</source>" to "</syntaxhighlight>" |
||
| (One intermediate revision by the same user not shown) | |||
| Line 5: | Line 5: | ||
=== Description === | === Description === | ||
Returns all elements from the given list as a tuple. | Returns all elements from the given list as a tuple. | ||
< | <syntaxhighlight lang="lua"> | ||
(any) = table.unpack(t,i,j) | (any) = table.unpack(t,i,j) | ||
</ | </syntaxhighlight> | ||
=== Parameters === | === Parameters === | ||
Latest revision as of 13:33, 13 July 2023
Available since: Gideros 2022.3
Class: table
Description
Returns all elements from the given list as a tuple.
(any) = table.unpack(t,i,j)
Parameters
t: (table) table to unpack
i: (number) start at index i optional, default = 1
j: (number) end at index j optional, default = length of table
Return values
Returns (any) the unpacked values from table