FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
lua2c/examples-lua/table.lua at master · davidm/lua2c · GitHub
davidm
/
lua2c
Public
Notifications
You must be signed in to change notification settings
Fork
54
Star
312
Code
Issues
3
Pull requests
1
Actions
Projects
Wiki
Security and quality
0
Insights
Additional navigation options
Code
Issues
Pull requests
Actions
Projects
Wiki
Security and quality
Insights
Expand file tree
Breadcrumbs
lua2c
/
examples-lua
/
table.lua
Copy path
More file actions
More file actions
Latest commit
History
History
History
12 lines (11 loc) · 283 Bytes
Breadcrumbs
lua2c
/
examples-lua
/
table.lua
Copy path
File metadata and controls
12 lines (11 loc) · 283 Bytes
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
--
make table, grouping all data for the same item
--
input is 2 columns (item, data)
local
A
while
1
do
local
l
=
io.read
()
if
l
==
nil
then
break
end
local
_
,
_
,
a
,
b
=
string.find
(
l
,
'
"?([_%w]+)"?%s*(.*)$
'
)
if
a
~=
A
then
A
=
a
io.write
(
"
\n
"
,
a
,
"
:
"
)
end
io.write
(
"
"
,
b
)
end
io.write
(
"
\n
"
)
Back
|
FazBrowse Home
|
New Git URL