Start New Discussion within our Software Development Community

;Read and array of positive numbers.Create two arrays one containing numbers in the interval [120,130] and the ;other one outside this interval.

data segment para public 'data'
sir db 1,2,120,140
len dw $-sir
sir1 db 6 dup(?)
sir2 db 6 dup(?)
data ends
code segment para public 'code'
start proc far
assume cs:code,ds:data
    push ds
    mov ax,data
    mov ds,ax
    xor ax,ax

    mov si,0
    mov di,0
    mov cx,len
    mov bx,0
    cmp sir[bx],130
    JB l
    cmp sir[bx],120
    jA l

    mov al,sir[bx]
    mov sir1[si],al
    inc si
    jmp gata
        mov al,sir[bx]
        mov sir2[di],al
        inc di
        inc bx
        loop b
mov ah,4cH
int 21h

start endp
code ends
end start

The problem is that when I want to watch the initial array's content(sir) displays a smiley face as in the picture below and same when I move it(the number) to another array,but the register shows the decimal value!Any idea why ?Is there smting wrong with my code? lala