[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: creating a table from a file
- From: Luiz Henrique de Figueiredo <lhf@...>
- Date: Mon, 27 Jan 2014 13:12:03 -0200
> > l={}
> > for line in io.lines("table.txt") do
> >> l[#l+1] = line
> >> end
I'd go for
local f=assert(io.open("table.txt")
local s=f:read("*a"):gsub("\n",",")
f:close()