Sha256: 15b36dcee9b4ec5cb226909fcb9cf88248fb81a3019b9412492fd2994813ac88
Contents?: true
Size: 468 Bytes
Versions: 396
Compression:
Stored size: 468 Bytes
Contents
return function(s) local rows = {} for line in s:gmatch('[%d ]+') do local row = {} for element in line:gmatch('%d+') do table.insert(row, tonumber(element)) end table.insert(rows, row) end return { row = function(which) return rows[which] end, column = function(which) local column = {} for _, row in ipairs(rows) do table.insert(column, row[which]) end return column end } end
Version data entries
396 entries across 396 versions & 1 rubygems