我希望这段代码只打印'B',但它在'B'之后打印一些垃圾,如何删除垃圾?我正在使用 NASM。
SECTION .data
num: db "" , '$' ; reserves 1 byte in memory
SECTION .text
org 0 x100 ; assembler directive
mov ax , 33 ; this is recommended number representation
mov cx , 33 ; works smooth , but not recommended
add ax , cx
mov [num] , al ; saves result to memory
mov dx , num
mov ah , 0x9 ; system interrupt
int 0x21 ; system interrupt for printing
mov ah , 0x4c ; last two lines are
int 0x21 ; synonymous to return 0;