Use an insertion sort to sort an array, Programming Languages

Use an insertion sort to sort an array (sequence) of long word integers. The size of the list will appear just before the list itself. Use the same labels as in this example:

LENGTH: DC.W 6
SPOT: DC.L 66,5,30,-4,10,12

The program must work for lists of between 1 and 20 numbers at a minimum, and should really work for much longer lists.

Include comments.

It is normal to turn this kind of application into a subroutine. The subroutine might well have two parameters. The first would be a size, and the second the location of the list of long word integers to be sorted. Thus: sort(int size, int *ai) might be a C prototype. So for the example above the actual parameters would be 6, and the address symbolized by SPOT.

Consider this a two part assignment. The first part is to get the insertion sort to work. The second part is to create and test a subroutine which  uses the code created in the first part. There will be separate due dates.

Program starts

                ORG   $0

DC.L  $8000

DC.L  START

                ORG   $2000

Posted Date: 3/25/2013 5:37:31 AM | Location : United States







Related Discussions:- Use an insertion sort to sort an array, Assignment Help, Ask Question on Use an insertion sort to sort an array, Get Answer, Expert's Help, Use an insertion sort to sort an array Discussions

Write discussion on Use an insertion sort to sort an array
Your posts are moderated
Related Questions
I have a half done program that needs to be finished for a class by tomorrow night. The program will create a database and print out a menu ofoptions (already done). Ive already

As an XML expert you are required to model a system for an online bookshop. After an interview with the shop manager you have the following information: The detail of th

I need help with making a assembly program that uses Hoffman''s coding scheme to compress a text file.

I have an assignment that requires from me to run multiple clients and one server ( Corba)

program the following exercises using JAVA and JENA API: SPARQL endpoint to be queried: QUERY:">http://services.data.gov.uk/education/sparql QUERY: What are the school’s names th

COS-101: INTRODUCTION TO COMPUTERS PROJECT DESCRIPTION The Computer Fundamentals Project provides you with a chance to apply what you have learned about computer fundamentals to

write a program to draw a cow. Now, draw a cow standing amongst the grass, with (say) 500 blades of grass. Each blade of grass should be a separate random green line. Do all your d

Normal 0 false false false EN-US X-NONE X-NONE MicrosoftInternetExplorer4

W.A.S.S to display all the files in a specified directory in the following format: File  size in K        Date   Protection    Owner Program echo -e "Enter dir : \c" read di

JSP QUIZ ASSIGNMENT SHOULD BE FUNCTIONAL ON ECLIPSE QUIZ HAS TOTAL 20 QUESTIONS REGARDING VARIOUS CAPITALS OF COUNTRIES. WELCOME PAGE OFFERS USER TO ENTER HIS NAME. THEN USER C