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

Program, write a program assembly language for adding two 3*3 matrix

write a program assembly language for adding two 3*3 matrix

Program of generate a random number, This is a short program to practice as...

This is a short program to practice assembly language loops and if/else statements. You will use various jump commands and the cmp instruction. The program will generate a random

Efficient assembly language program, (1) Write a program that will: (a) dis...

(1) Write a program that will: (a) display "Enter Your Name:" (b) convert the entered name to Capital letters (if small), If any other character is entered, the program wil

Rep-string manipulation instruction-microprocessor, REP : Repeat Instructi...

REP : Repeat Instruction Prefix :- This instruction is utilized as a prefix to other instructions. The instruction in which the REP prefix is provided, is executed repetitively

8279 keyword /display controller-microprocessor, 8279 Keyword /Display Cont...

8279 Keyword /Display Controller : Figure shows the structure of 8279 and its interface to the bus. Addressing is according to the table given below. CS        RD

Microprocessor, from pin description it seems that 8086 has 16 address/data...

from pin description it seems that 8086 has 16 address/data lines i.e.AD0_AD15.The physical address is however is larger than 2^16.How this condition can be handled

Conditional branch instruction-microprocessor, Conditional branch Instructi...

Conditional branch Instruction When these type of instructions are executed, they transfer control of execution to the address mention relatively in the instruction, provided t

8088 timing system diagram-Microprocessor, 8088  Timing System Diagram ...

8088  Timing System Diagram The 8088 address/data  bus is divided  in 3 parts (a) the lower 8 address/data  bits, (b) the middle 8 address bits, and (c) the upper 4 status/

Develop an assembly language program, • To develop an assembly language pro...

• To develop an assembly language program to control a "simulated" intelligent domestic lighting system with the intention of deterring burglary. • To produce a schematic circuit d

And-logical instruction-microprocessor, AND: Logical AND: This instruction...

AND: Logical AND: This instruction bit by bit ANDs the source operand that might be an immediate, or a memory location or register to the destination operand that might be a memor

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