DATA SEGMENT MEM DB 12H,91H,73H,64H,20H,0A5H,0D1H,91H,0A2H,00H PLUS DB 00H ZERO DB 00H NEGO DB 00H DATA ENDS STACK SEGMENT STACK ENDS CODE SEGMENT ASSUME CS:CODE,DS:DATA,SS:STACK START: MOV AX,DATA MOV DS,AX MOV CX,10 LEA BX,MEM DEC BX SIGN: INC BX M…
Author       :  叨陪鲤 Email         : vip_13031075266@163.com Date          : 2021.01.23 Copyright : 未经同意不得转载!!! Version    : 第一章 二分法 Reference:<LeetCode刷题笔记之模板整理> 目录 1. 二分法 1.1 什么是二分查找 1.2 如何识别二分法 1.3 二分法模板 1.3.1 模板一 1.3.2 Lc69:x的平方根 1.3.3 Lc374:猜数大小…
DATA SEGMENT ORG 1000H INFO DB 1,2,3,4,5,70H,71H,72H,80H,92H MAX DB 00H DATA ENDS CODE SEGMENT ASSUME CS:CODE,DS:DATA START: MOV AX,DATA MOV DS,AX MOV CX,10 MOV BX,1000H DEC BX SIGN: INC BX MOV DL,BYTE PTR [BX] CMP DL,MAX JA CHANGE NEXT: LOOP SIGN MO…
DATA SEGMENT     M DB 36H     N DB 95H     RESAULT1 DB 'M>N$'     RESAULT2 DB 'M<N$' DATA ENDS STACK SEGMENT     DB 1000 DUP(?) STACK ENDS CODE SEGMENT     ASSUME CS:CODE,DS:DATA,SS:STACK START:     MOV AX,DATA     MOV DS,AX     LEA SI,M     LEA DI,…
DATA SEGMENT X DB 10 Y DB 20 Z DB 00 DATA ENDS CODE SEGMENT ASSUME CS:CODE,DS:DATA START: MOV AX,DATA MOV DS,AX MOV AL,X ADD AL,Y MOV CL,3 SHL AL,CL SUB AL,X MOV CL,2 SHR AL,CL MOV AH,4CH INT 21H CODE ENDS END START…
DATA SEGMENT INFO DB 'HOW ARE YOU!$' DATA ENDS CODE SEGMENT ASSUME CS:CODE,DS:DATA START: MOV AX,DATA MOV DS,AX LEA DX,INFO MOV AH,09H INT 21H MOV AH,4CH INT 21H CODE ENDS END START…
DATA SEGMENT DATA ENDS CODE SEGMENT ASSUME CS:CODE,DS:DATA START: MOV AX,DATA MOV DS,AX MOV CX,8 MOV AH,02H MOV DL,40H SIGN: INC DL INT 21H LOOP SIGN MOV AH,4CH INT 21H CODE ENDS END START…
DATA SEGMENT ORG 2000H INFO DB 1,2,3,4,5,70H,71H,72H,80H,92H N_NUMS DB 00H P_NUMS DB 00H DATA ENDS CODE SEGMENT ASSUME CS:CODE,DS:DATA START: MOV AX,DATA MOV DS,AX MOV CX,10 MOV BX,2000H DEC BX SIGN: INC BX TEST BYTE PTR [BX],80H JNZ NEG_NUM INC P_NU…
1.若两个数中有一个是奇数,一个是偶数,则将它们互换储存地址 2.若两个数都是奇数,则分别加一 3.若两个数都是偶数,则不变 DATA SEGMENT A DB 12H B DB 25H DATA ENDS STACK SEGMENT STACK ENDS CODE SEGMENT ASSUME CS:CODE,DS:DATA,SS:STACK START: MOV AX,DATA MOV DS,AX MOV AL,0 MOV BL,A TEST BL,01H JZ ADD_TIME_1 ONE…
leecode刷题(19)-- 最长公共前缀 最长公共前缀 编写一个函数来查找字符串数组中的最长公共前缀. 如果不存在公共前缀,返回空字符串 "". 示例 1: 输入: ["flower","flow","flight"] 输出: "fl" 示例 2: 输入: ["dog","racecar","car"] 输出: "" 解释:…