Hi!
How to insert value to Two-dimensional array?
1 2 3 | a = {0,0,0,0,0,0,0,0, 1,1,1,1,1,1,1,1} |
not understanding your question then array given above is not 2d
are you asking how to make it 2d or how to insert a new value to the array
This will create a multi-dimensional array of 10 x 10 with every value set to zero:
1 2 3 4 5 6 7 | myarray = {} for f=1, 10 do myarray[f] = {} for g=1, 10 do myarray[f][g] = 0 end end |
热门文章
GameCenter LeaderBoards and Achievements Enabled Through OpenFeint
send message and call to a person
Forum: Report Spam + PM
[INSTALL_PARSE_FAILED_NO_CERTIFICATES]
[SOLVED] Director ERROR: Failed to execute new( params ) function on 'screen1'
Too many (200) local variables
Corona SVG Level Builder released. Drag and drop physics level editor with Inkscape and SVG.
Small bug in Collectible Items example
Pivot Joints and apparent elasticity
Can't make removeSelf() delayed
send message and call to a person
Forum: Report Spam + PM
[INSTALL_PARSE_FAILED_NO_CERTIFICATES]
[SOLVED] Director ERROR: Failed to execute new( params ) function on 'screen1'
Too many (200) local variables
Corona SVG Level Builder released. Drag and drop physics level editor with Inkscape and SVG.
Small bug in Collectible Items example
Pivot Joints and apparent elasticity
Can't make removeSelf() delayed
相关文章
Test build for device
Problem with custom fonts on Windows Simulator
Dynamic triangle creation not possible?
system.OpenUrl local file
Physics - Find Touching Objects
tableview list superimposed on the old one
Problem with timer.pause() and timer.resume()?
Confused on using depreciated stuff
Paid jobs?
vortex demo
Problem with custom fonts on Windows Simulator
Dynamic triangle creation not possible?
system.OpenUrl local file
Physics - Find Touching Objects
tableview list superimposed on the old one
Problem with timer.pause() and timer.resume()?
Confused on using depreciated stuff
Paid jobs?
vortex demo
corona forums © 2003-2011