Array concatenation: Difference between revisions
Content added Content deleted
Puppydrum64 (talk | contribs) |
Puppydrum64 (talk | contribs) (→{{header|Z80 Assembly}}: formatting) |
||
Line 3,854: | Line 3,854: | ||
Credit to Keith of [https://www.chibiakumas.com ChibiAkumas] for creating it. |
Credit to Keith of [https://www.chibiakumas.com ChibiAkumas] for creating it. |
||
<lang z80> |
<lang z80> org $8000 |
||
org &8000 |
|||
ld hl,TestArray1 ; pointer to first array |
ld hl,TestArray1 ; pointer to first array |
||
ld de,ArrayRam ; pointer to ram area |
ld de,ArrayRam ; pointer to ram area |
||
Line 3,878: | Line 3,877: | ||
ds 24,0 ;24 bytes initialized to zero |
ds 24,0 ;24 bytes initialized to zero |
||
org |
org $9000 |
||
TestArray2: |
TestArray2: |
||
byte |
byte $23,$45,$67,$89 |
||
; just to prove that this doesn't rely on the arrays |
; just to prove that this doesn't rely on the arrays |
||
; being "already concatenated" I've stored them |
; being "already concatenated" I've stored them |
||
; in the reverse order. |
; in the reverse order. |
||
TestArray1: |
TestArray1: |
||
byte |
byte $aa,$bb,$cc,$dd,$ee,$ff</lang> |
||
{{out}} |
{{out}} |