Question: Assembly Language Problem Help: I already finished problem 1 but I really need help with problems 2 & 3: printAlpha.s: .intel_syntax noprefix .data n1: .int

Assembly Language Problem Help:

I already finished problem 1 but I really need help with problems 2 & 3:

Assembly Language Problem Help: I already finished problem 1 but I really

printAlpha.s:

.intel_syntax noprefix .data n1: .int 97 n2: .int 122

.text .globl main

main: mov ebx, DWORD PTR n1 loop: cmp ebx, DWORD PTR n2 jg end mov edi, ebx call putchar inc ebx jmp loop end: mov edi, 10 call putchar mov eax, 0 ret

OR, here is a picture of printAlpha.s:

need help with problems 2 & 3: printAlpha.s: .intel_syntax noprefix .data n1:

After successfully logging into Highlander AFS using SSH client such as MobaXterm, assemble, link, and run the "printAlpha.s" assembly language program using the following steps: 1. as printAlpha.s -o printAlpha.o 2. gcc printAlpha.o 3. ./a.out The program prints the alphabetical characters from a' to 'z' on one line as follows: $./a.out abcdefghijklmnopqrstuvwxyz Make 2 copies of the printAlpha.s file, and call them mountainTerrain.s, and triangle.s Problem 1 Annotate the printAlpha.s file with line comments describing your understanding of what each line does. For example, line 19 should be annotated as follows call putchar # Call the C standard library function putchar(int) Problem 2 Edit the mountainTerrain.s file and change the code to alternate between upper and lower case characters while printing the alphabet. The output should be as follows: $ ./a.out AbCdEfGhIjKIMnOpQrStUvwxYz Problem 3 Edit the triangle.s file and change the code to print a triangle using lower case characters. The output should be as follows: . /a. out abcdefghijklmnopqrstuvwxyz abcdefghijklmnopqrstuvwxy abcdefghijklmnopqrstuvwx abcdefghijklmnopqrstuvw abcdefghijklmnopqrstuv abcdefghijklmnopqrstu abcdefghijklmnopqrst abcdefghijklmnopqrs abcdefghijklmnopqr abcdefghijklmnopq abcdefghijklmnop abcdefghijklmno abcdefghij k1mn abcdefghijklm abcdefghijkl abcdefghijk abcdefghij abcdefghi abcdefgh abcdefg abcdef abcde abcd abc ab

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!