单词记忆测试器程序设计
发布时间:2021-06-11
发布时间:2021-06-11
微机原理
STACK SEGMENT STACK
DB 50 DUP(0)
STACK ENDS
DATA SEGMENT
WORD1 DB 300 DUP(0)
WORD2 DB 20 DUP(0)
MSG0 DB 'THE NUMBER OF WORD YOU HAVE REMEBERED : $' MSG1 DB 'THE NUMBER OF WORD YOU HAVE NOT REMEBER :$ '
MSG2 DB 'PLEASE INPUT WORDS,END WITH END.PRESS ENTER TO
END INPUT AND START TEST!',0AH,0DH,'$'
MSG3 DB 'THE WORD YOU HAVE NOT REMEBERED:$'
MSG4 DB 'THE SOURCE WORD:$'
STR1 DB 0AH,'PERSS K OR U TO JUDGE IF YOU KNOW THIS
WORD!YOU CAN PRESS N OR L TO DISPLAY THE NEXT WORD!',0AH,'$'
STR2 DB 0AH,'PERSS N OR L TO CHOOSE THE NEXT WORD,PERSS O
IS JUMP OUT THE GAME!',0AH,'$'
RATE0 DB 'THE RIGHT RATE IS:$'
DATA ENDS
CODE SEGMENT
ASSUME CS:CODE , DS:DATA, SS:STACK
START: MOV AX,DATA ;取数据段地址
MOV DS,AX
MOV CX,0
MOV DI,OFFSET WORD2
PUSH DI
MOV DX,OFFSET MSG2 ;调用中断显示字符串
MOV AH,09H
INT 21H
LEA SI,WORD1
INPUT: INC SI
MOV AH,01H ;输入单词
MOV DL,0FFH
INT 21H
MOV [SI],AL
CMP AL,0DH
JZ FIRST
JMP INPUT
FIRST: CALL CLEAR
上一篇:孩子必读的图书清单
下一篇:HAM英文字母解释法