14 lines
321 B
Text
14 lines
321 B
Text
local function make_list(sep)
|
|
local counter = 0
|
|
local function make_item(name)
|
|
counter += 1
|
|
return $"{counter}{sep}{name}"
|
|
end
|
|
local items = {}
|
|
for {"first", "second", "third"} as name do
|
|
items:insert(make_item(name))
|
|
end
|
|
print(items:concat("\n"))
|
|
end
|
|
|
|
make_list(". ")
|