Write an assembly language program that uses the terminal I/O routines to handle the following task.
Prompt for and read in a collection of names and scores and store them in arrays. Set up a loop to do this reading; have the loop terminate when the entered name consists of only a carriage return. The prompts may be something like Name? and Score? You should allow for up to 50 names and scores. The names are variable length and should be stored packed together in an array. An associated array of name lengths should also be built so that you can determine where each name starts in the array later. As an example o f what the arrays should look like, assume that four names and scores are read in: Dan 174, Elizabeth 160, Mark 139, and Hannah 168. Assuming you store the scores and lengths as longwords, you would then have the following, reading right to left with numbers in hexadecimal.
hannaHkraMhtebazilEnaD NAMES
00000006000000040000000900000003 LENGTHS
000000A80000008B000000A0000000AE SCORES
Next, compute the average for all scores read in.
Finally, display an appropriate heading (showing the average score) and then display the names of each person who has a score that is above the average (i.e., strictly greater than the average). For example, with the above data, you program could display
People above the average of 160 Dan HannahHandin an assembly listing of your program, i.e., print the .LIS file. DO NOT USE THE TYPE COMMAND TO PRODUCE THIS LISTING. Also, handin a listing showing the execution of your program TWICE, once with the sample data above and once with data of your own (as long as it consists of at least six names and scores). This second listing may be produced easily by using CARBON and printing the resulting AUDIT.LOG file. DO NOT REASSEMBLE AND LINK BETWEEN EXECUTIONS.