2025-01-17 14:53:31 +00:00
|
|
|
## Two-Plus-Two
|
|
|
|
|
|
|
|
<pre class="atari">
|
|
|
|
10 ;
|
|
|
|
20 ;ADDNRS.SRC
|
|
|
|
30 ;
|
2025-01-17 15:17:21 +00:00
|
|
|
40 *=$0600 ; Begin program at 1536 decimal.
|
2025-01-17 14:53:31 +00:00
|
|
|
50 ;
|
2025-01-17 15:17:21 +00:00
|
|
|
52 ; See notes below this snippet for details
|
|
|
|
54 ;
|
|
|
|
60 CLD ; Clear Decimal Mode
|
|
|
|
70 ADDNRS CLC ; Clear Carry
|
|
|
|
80 LDA #2 ; Load Accumulator From Immediate 2
|
|
|
|
90 ADC #2 ; Add Immediate 2 To Accumulator With Carry
|
|
|
|
100 STA $CB ; Store Accumulator To Location 203
|
|
|
|
110 RTS ; Return To Stack
|
|
|
|
120 .END ; Program End Macro
|
2025-01-17 14:53:31 +00:00
|
|
|
</pre>
|