Customer Service Chat
Get quote & make Payment
NASM assembly language programming, Assembly Language
NASM assembly language program:
Consider a sequence of 19 strictly positive decimal digits, most likely
stored in an array. There are obviously duplicates, and the sequence is
unsorted. You may use the sequence length in your program.
Your job is to compute and print the _median_ of this sequence. Since the
sequence length is odd, the median occupies the central position when the
sequence is sorted.
Sorting the sequence might be challenging as your first assembly-language
program, but there is an easier way. All you need to master is looping,
array indexing, adding 1, and comparing.
Give yourself an auxiliary array ''count'' that records the number of times
each digit appears in the sequence.
A linear scan through the sequence is sufficient to compute ''count''.
A second linear scan through ''count'' is sufficient to compute the median.
This program is to be written in NASM.
Here is an outline of the NASM source text:
seq dd 0, 1, 9, 1, 9, 1, 9, 3, 8, 3,
3, 8, 4, 7, 5, 7, 5, 6, 5, 4 ; array of length 20
count dd 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ; array of length 10
Posted Date: 10/17/2012 11:10:57 AM | Location : United States
Ask an Expert
NASM assembly language programming, Assignment Help, Ask Question on NASM assembly language programming, Get Answer, Expert's Help, NASM assembly language programming Discussions
Write discussion on NASM assembly language programming
Your posts are moderated
Write your message here..
Code, How to print strings in Right Triangle form?
How to print strings in Right Triangle form?
Right triangle, code, Assembly Language How to print strings in Right Tria...
code, Assembly Language How to print strings in Right Triangle form?
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
Modes of 8255 a-microprocessor, The modes are determined by the contents of...
The modes are determined by the contents of the control register, whose format is given in Figure These modes are: Mode 0: If a group is in mode 0, it is divided into 2 sets.
Cache memory-microprocessor, Cache Memory Caching is a technology based...
Cache Memory Caching is a technology based on the memory subsystem of any computer. The majoraim of a cache is to accelerate the computer while keeping the cost of the computer
Ocw-microprocessor, There are 3 kinds of OCWs. The command word OCWI is u...
There are 3 kinds of OCWs. The command word OCWI is utilized for masking the interrupt requests; when the mask bit corresponding to an interrupt request is value 1, then the requ
Assembly HW help, I was wondering if you guys could offer me some advice an...
I was wondering if you guys could offer me some advice and help on how to proceed - not answers- for a homework problem I am attempting. I am currently working on a "bomb" project
Interrupt table-how interrupt table processed-microprocessor, Interrupt Tab...
Interrupt Table Each interrupt level has a booked memory location, called an interrupt vector. All these vectors (or pointers) are stored in the interrupt table. Table lies at
Program to perform a conversion on characters in a text file, Write an asse...
Write an assembly language program to perform a rot13 1 conversion on characters in a text file. The program should read charatcers from the input file, perform the rot13 convers
Multiplication, how we can multiply two 8 bit number with rotation
how we can multiply two 8 bit number with rotation
Accounting Assignment Help
Economics Assignment Help
Finance Assignment Help
Statistics Assignment Help
Physics Assignment Help
Chemistry Assignment Help
Math Assignment Help
Biology Assignment Help
English Assignment Help
Management Assignment Help
Engineering Assignment Help
Programming Assignment Help
Computer Science Assignment Help
IT Courses and Help
Why Us ?
~24x7 hrs Support
~Quality of Work
~Time on Delivery
~Privacy of Work
Human Resource Management
Literature Review Writing Help
Follow Us |
T & C
Copyright by ExpertsMind IT Educational Pvt. Ltd.