I have been having problems on how can I revise or if someone could me a code on emu8086 on how to convert uppercase string into lowercase..the code below converts lowercase into uppercase..how can i revise it? Thanks in advance
org 100h
.model small
.stack 200
.data
msg db 'enter a string in small letter: ','$'
msg1 db 'this is what you entered in capital: ','$'
string db 20, 22 dup('?')
crlf db 0Dh,0Ah, '$' ; new line code.
.code
.startup
lea dx, msg
mov ah, 09h
int 21h
lea dx, string
mov ah, 0ah
int 21h
mov bx, dx
mov ah, 0
mov al, ds:[bx+1]
add bx, ax ; point to end of string.
mov byte ptr [bx+2], '$'
lea dx, crlf ;new line
mov ah, 09h
int 21h
lea bx, string
mov ch, 0
mov cl, [bx+1]
add bx, 2
upper_case:
and byte ptr [bx], 11011111b
inc bx ; increment
loop upper_case
lea dx, msg1
mov ah, 09h
int 21h
lea dx, string+2
mov ah, 09h
int 21h
ret
end