Array: Difference between revisions
m
→Assembly
Puppydrum64 (talk | contribs) m (→Assembly) |
Puppydrum64 (talk | contribs) m (→Assembly) |
||
Line 64:
DC.B 40,41,42,43,44
DC.B 50,51,52,53,54</lang>
It is <b>much</b> easier to work with arrays in assembly if all rows are the same length. The best way to deal with a ragged or jagged array is to pad the ends of each shorter row with arbitrary bytes. This lets you select an arbitrary row with a simple bit shift applied to the index.
Iteration over the elements of an array is fairly straightforward.
|