鱼C论坛

 找回密码
 立即注册
查看: 3392|回复: 11

第六章 检测点6.1(2)

[复制链接]
发表于 2012-4-25 20:37:22 | 显示全部楼层 |阅读模式

马上注册,结交更多好友,享用更多功能^_^

您需要 登录 才可以下载或查看,没有账号?立即注册

x
检测点6.1

(2)下面的程序实现依次用内存0:0~0:15单元中的内容改写程序中的数据,数据的传送用栈来进行。栈空间设置在程序内。完成程序:

assume cs:codesg

codesg segment

        dw 0123h,0456h,0789h,0abch,0defh,0fedh,0cbah,0987h

        dw 0,0,0,0,0,0,0,0,0,0

start:  mov ax, codesg ;或mov ax, cs

        mov ss,ax

        mov sp, 24h    ;或mov sp, 36     // 主要是这个的 24H 是怎么得来的  求大牛解释
        mov ax,0

        mov ds,ax

        mov bx,0

        mov cx,8

    s:  push [bx]

         pop cs:[bx]   ;或 pop ss:[bx]

        add bx,2  

        loop s

        mov ax,4c00h

        int 21h

codesg ends

end start

小甲鱼最新课程 -> https://ilovefishc.com
您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

小黑屋|手机版|Archiver|鱼C工作室 ( 粤ICP备18085999号-1 | 粤公网安备 44051102000585号)

GMT+8, 2025-10-8 03:02

Powered by Discuz! X3.4

© 2001-2023 Discuz! Team.

快速回复 返回顶部 返回列表