Odd and even numbers, Assembly Language

Assignment Help:
hi, i''m new to assembly language and my teacher told us to look for an example of the odd and even numbers program using debug.exe in ms dos as a guide since we just started. please help me? how do you make the odd and even numbers in assembly language?

Related Discussions:- Odd and even numbers

Bitwise logical and shift operations, Part A: Bitwise Logical and Shift Op...

Part A: Bitwise Logical and Shift Operations Create a SPARC assembly language program that extracts a bit-field from the contents of register %l0. The position of the rightmos

Assebmly code, You have to write a subroutine (assembly language code using...

You have to write a subroutine (assembly language code using NASM) for the following equation.

Operating systems, what would be the typical pricing for helping out on Ope...

what would be the typical pricing for helping out on Operating systems 1 assignments at UCI

Machine code, do you type assembly code or machine code instructions like b...

do you type assembly code or machine code instructions like b8 0100000 to add to register EAX straigt onto dos command line or do you have to same in a file and what extension woul

Programming assembly language, Write an 8086 program to find out the number...

Write an 8086 program to find out the number of positive numbers and negative numbers from a given series of signed numbers include flow chart ..

Hi, i have a question.

i have a question.

#title:Shifitng of memory, Ask 2. Exchange higher byte of AX and higher byt...

Ask 2. Exchange higher byte of AX and higher byte of BX registers by using memory location 0160 in between the transfer. Then stores AX and BX registers onto memory location 0174 o

Entering a program-microprocessor, Entering a Program In this section, ...

Entering a Program In this section, we will explain the procedure for entering a small program on IBM PC with DOS operating system. Assume a program of addition of 2 bytes, as

Add-arithmetic instruction-microprocessor, ADD:  Add :- This instruction ...

ADD:  Add :- This instruction adds an immediate contents of a memory location specified in the a register ( source ) or instruction to the contents of another register (destinat

diana

10/1/2012 7:15:03 AM

.model small

.data
arr1 db 1,2,3,1,3,5,6,3,4,5
OddArr db 10 dup(?)
EvenArr db 10 dup(?)
OddAdd db 0
EvenAdd db 0

.code
mov ax,@data
mov ds,ax

LEA BX,arr1
LEA SI,OddArr
LEA DI,EvenArr
mov cx,10
mov dh,02

L1:
mov ah,00
mov al,[BX]
mov dl,al
div dh
cmp ah,00
je EVEN1
mov [DI],dl
add OddAdd,dl
INC DI
INC BX
Loop L1
jmp CAL


EVEN1:
mov [SI],dl
add EvenAdd,dl
INC SI
INC BX
Loop L1

CAL:
mov ax,0000
mov bx,0000
mov al,OddAdd
mov bl,EvenAdd

mov ax,4C00h
int 21h

end

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd