1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
Anastasy [175]
3 years ago
5

Write an ALP to separate odd and even numbers from an array of N numbers; arrange odd

Computers and Technology
1 answer:
Anuta_ua [19.1K]3 years ago
6 0

Answer:

2000H           LXI H, 2000H           memory pointer first is initialized

2003H           LXI D, 2100H           memory pointer second is initialized

2006H           MVI C, 32H  the counter, is initialized

2008H           MOV A, M     We achieve the number

2009H           ANI 0lH         We now check for an odd number

200BH           JZ 2011H      If it is even then never store it

200EH           MOV A, M     Now we achieve the number again

200FH           STAX D         The number is stored in the result list.

2010 H          INX D            Pointer 2 is incremented

2011 H          INX H            Pointer 1 is incremented

2012H           DCR C          The counter is decremented

2013H           JNZ 2008H   If it is not zero, then repeat it

2016H            LXI H, 2000H         the memory pointer 1st, is initialized

2019H            LXI D, 2200H         the memory pointer 2nd is initialized

201CH          MVI C, 32H  the counter, is initialized

201EH           MOV A, M     Achieve the number

201FH           ANI 0lH           Test whether it is even or not

2021H           JNZ 2027H   If it is odd, then never store it

2024H           MOV A, M      Achieve the number

2025H           STAX D        Save the number in the result list

2026H           INX D           Now increment the pointer number 2

2027H           INX H           Increment pointer number 1

2028H           DCR C          Counter is to be decremented

2029H           JNZ 201EH  If! 0 then repeat it

202CH          HLT    Stop

Explanation:

Please check the answer section.

You might be interested in
Spoderman memes<br> im scared-
DENIUS [597]

Don't be afraid of spooderman. He's hot.

4 0
3 years ago
Read 2 more answers
What is the function of the operating system of a computer?
irina1246 [14]

Answer:

It allows the CPU to communicate with input and output devices.

Explanation:

Plzzzzzzzzzzzzz give me brainiest

6 0
3 years ago
An exact-match query is:
Greeley [361]

Answer:

C. Where a record is returned if its unique identifier matches the search value

Explanation:

Exact match is a Google keyword match type that allows you show your adverts when searcher type the exact word or phrase you are bidding on. An exact match query will always return records that matches what is being searched on.

5 0
3 years ago
Learning in a digital environment is also called learning.
aleksandrvk [35]

Learning in a digital environment is also called O<u>nline Learning.</u>

Explanation:

The main difference between the digital learning and the traditional form of learning is that

  • Digital Learning takes place online or virtually.
  • The traditional Learning is conducted in a classroom building.
  • Another factor that differentiate the 2 forms of learning is that the instructor or the trainer may not be present at the real-time but in a traditional training method the trainer or the instructor is present in person
6 0
4 years ago
Read 2 more answers
As a photographer, what will be the driving force behind everything that you produce?
GREYUIT [131]

Answer:

You have to like it to be successful in photography.

Explanation:

8 0
3 years ago
Other questions:
  • If people have humility, they don’t tend to see themselves as overly or more important than others. True False
    13·1 answer
  • Torque is defined as _____.
    7·1 answer
  • hardtack was a. a new cone-shaped bullet. c. a type of biscuit. b. a sharp turn made on command. d. a type of body armor.
    6·1 answer
  • In molecular biology the "alphabet" of genes consists of four chemicals (called nucleotides) represented by the letters A C G T.
    12·2 answers
  • Which of the following is NOT an e-reader you would use as an alternative to carrying around a set of textbooks?
    13·1 answer
  • Three Strings someone help
    15·1 answer
  • 1. Write the syntax of the following HTML commands by using any one attribute
    6·2 answers
  • A program to that would accept the length and width of a rectangle and display the results​
    14·1 answer
  • Jen's house contains the following devices:
    13·1 answer
  • ______ requires that any electronic communication must be backed up and secured with reasonable disaster recovery infrastructure
    6·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!