Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ;===[ Начало сегмента кода ]============================================
- MYCODE: segment .code
- org 100h ; Обязательная директива ТОЛЬКО для COM-файлов
- START: ;---[ Точка старта ]---------------------------------------------------------------------
- ;cmp: если 1ый>=2го - sf=0, если 1ый=2му, zf=1 js, esli sf=1, jns, esli sf=0, jz, esli zf=1, jnz, esli zf=0
- mov ax, 5678h
- mov bx, 2
- mov cx, 3
- mov dx, 4
- or bx, 0ffffh
- and bx, ax
- shl bx, 12
- shr bx, 12
- or cx, 0ffffh
- and cx, ax
- shl cx, 8
- shr cx, 12
- ;tut b=posl.cifre, c=predposl.cifre
- a:
- or dx, 0ffffh
- and dx, bx
- and dx, cx
- shl dx, 1
- xor bx, cx
- or cx, 0ffffh
- and cx, dx
- and dx, bx
- cmp dx, 1
- jns a
- or bx, cx
- or cx, 0ffffh
- and cx, ax
- shl cx, 4
- shr cx, 12
- b:
- or dx, 0ffffh
- and dx, bx
- and dx, cx
- shl dx, 1
- xor bx, cx
- or cx, 0ffffh
- and cx, dx
- and dx, bx
- cmp dx, 1
- jns b
- or bx, cx
- or cx, 0ffffh
- and cx, ax
- shr cx, 12
- c:
- or dx, 0ffffh
- and dx, bx
- and dx, cx
- shl dx, 1
- xor bx, cx
- or cx, 0ffffh
- and cx, dx
- and dx, bx
- cmp dx, 1
- jns c
- or bx, cx
- shr bx, 2
- shl bx, 8
- ; ... Здесь должно быть тело программы ...
- ;---[ Стандартное завершение программы ]----------------------------------------
- mov AX, 4C00h
- int 21h
- ;===[ Начало сегмента данных ]==========================================
- ; ...
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement