We have been given this project and I was wondering if someone could make my algorithm better using TASM and DOSBox.This is what I have done so far:idealmodel smallstack 10244datasegmsg1 db 'Enter Word: $'msg2 db 'Enter Hint: $'msg3 db 'Enter Guess(Press . to end guess)($'wrnmsg db 'Wrong!$'a3msg db 'Number of letters: $'a4msg db 'First two letters: $'a5msg db 'Last letter: $'a6msg db 'Second to the last letter: $'fail db ' Enter guess again($'secret db 21 dup('')hint db 101 dup('')guess db 21 dup('')endss db '): $'win db 'That is correct! You win!$'lose db 'Im sorry you lose$'cnt dw 0codesegPROC comparemov bx, 0mov di, 0loop1:    mov al, [secret+di]    mov ah, [guess+di]    cmp ah, al    jne no    cmp al, '$'    je endino:    mov bx, 1endi:    retENDPPROC mainmov ax, @datamov ds, axmov es, axlea dx, [msg1]mov ah, 9int 21hmov bx, 0scan:    mov ah, 1    int 21h    cmp al, '.'    je com    inc [cnt]    mov [secret+bx], al    inc bx    jmp scancom:    mov [secret+bx], '$'mov dx, 10mov ah, 2int 21hlea dx, [msg2]mov ah, 9int 21hlea dx, [hint]mov ah, 10int 21hmov dx, 10mov ah, 2int 21hlea dx, [msg3]mov ah, 9int 21hlea dx, [hint]mov ah, 9int 21hlea dx, [endss]mov ah, 9int 21hmov cx, 0loop2:    inc cx    mov bx, 0    scan2:        mov ah, 1        int 21h        cmp al, '.'        je com2        mov [guess+bx], al        inc bx        jmp scan2    com2:        mov [guess+bx], '$'        mov dx, 10        mov ah, 2        int 21h    call compare    cmp bx, 0    je right    lea dx, [wrnmsg]    mov ah, 9    int 21h    cmp cx, 3    je three    cmp cx, 4    je four    cmp cx, 5    je five    cmp cx, 6    je six    cmp cx, 7    je fail    man:    mov dx, 10    mov ah, 2    int 21h    lea dx, [fail]    mov ah, 9    int 21h    lea dx, [hint]    mov ah, 9    int 21h    lea dx, [endss]    mov ah, 9    int 21h    jmp loop2right:    lea dx [win]    mov ah, 9    int 21h    jmp end1fail:    lea dx, [lose]    mov ah, 9    int 21h    jmp end1three:    lea dx, [a3msg]    mov ah, 9    int 21h    lea dx, [cnt]    mov ah, 2    int 21h    jmp manfour:    lea dx, [a4msg]    mov ah, 9    int 21h    mov di, 0    mov si, 1    mov dh, [secret+di]    mov ah, 2    int 21h    mov dh, [secret+si]    int 21h    jmp manfive:    lea dx, [a5msg]    mov ah, 9    int 21h    mov di, [cnt]    mov dl, [secret+di]    mov ah, 2    int 21h    jmp mansix:    lea dx, [a6msg]    mov ah, 9    int 21h    mov di, [cnt]    dec di    mov ah, 2    int 21h    jmp manend1:    mov ah, 4ch    int 21hENDPEND mainWhat was required of us was a program that will simulate a guessing game where the first player will input the word to be guessed by the second player including a hint such as what category and other description. (Description can have a maximum of 100 characters).The second player will be given 6 chances to guess. If in the third try, the 2nd player still cannot guess the word, hints will be given for the succeeding unsuccessful guesses as cited below:Third unsuccessful try  Number of letters will be displayed on screenFourth unsuccessful try  First two letters will be revealedFifth unsuccessful try  Last letter will be revealedSixth unsuccessful try- Second to the last letter will be revealed
Guessing game where the first player inputs a word and a hint and the second player tries to guess it
assembly