为掌握用汇编语言编写排序程序的思路和方法。编写程序,在 s 中存放 100 个数,要求设计程序将这些数由小到大排序,排序后的数,仍放在该区域中,并显示排序后的结果。DATA SEGMENTSTR1 DB PLEASE INPUT SOME DATA,THE END FLAG IS$,$S DB 100DB ?DB 100 DUP(?)DATA ENDSCODE SEGMENTASSUME CS:CODE,DS:DATASTART:MOV AX,DATAMOV DS,AXLEA DX,STR1MOV AH,9INT 21HMOV DL,0AHMOV AH,2INT 21HLEA DX,SMOV AH,0AHINT 21HMOV SI,DXMOV DL,0AHMOV AH,2INT 21HMOV CL,SI+1MOV CH,0SUB CX,2MOV DX,CXDEC DXADD SI,2L1:MOV BL,SIINC SIMOV BH,SICMP BH,BLJG L2MOV SI,BLMOV SI-1,BHL2:LOOP L1LEA SI,SADD SI,2MOV CX,DXDEC DXJNZ L1LEA DX,SADD DX,2MOV AH,9INT 21HMOV AH,4CHINT 21HCODE ENDSEND START