Your Perfect Essay is Just a Click Away

Starting at $8.00 per Page

100% Original, Plagiarism Free, Customized to Your instructions!

Order Now My Account

I need help to debug and complete the code that I already did below. The result must match the Sample output that I attached.
array1 dword 1, 2, 3, 4, 5
array2 dword ($ -array1)/ type dword dup(0)
counter byte 0
align 4
displayTitle byte “— Array Copier —“, 0
msg1 byte “Index (0 – 4): “, 0
msg2 byte “Invalid Input: Try Again!”, 0
msg3 byte “Continue? y/n : “, 0
msg4 byte “—Program Terminated—“, 0
msg5 byte “H”, 0
main PROC
mov edx, offset displayTitle
call WriteString
call crlf; display title
mov edx,offset msg1
call WriteString
call readInt; read’s user input
cmp ax, 0; if statement user enter -1,
jl invalid; if less than jmp to invalid
or al, 32d; convert upper case to lower case
cmp al, “n”; cmp N and n
jz yes; jmp 0 if zero flag is set
cmp al, “y”; cmp Y with y
jz no; jmp if zero flag is set
jump invalid; otherwise jump to invalid
cmp ax,5
jg invalid
jmp copy
mov edx,offset msg1
call WriteString
call ReadInt
mov edx, offset msg4
call WriteString
mov edx, offset msg2
call WriteString
call crlf
jmp top
mov ecx,0h
mov ecx,lengthof array1
sub ecx,index
add esi,index
mov al,[esi]
mov [edi],al
add esi,type byte
add edi,type byte
loop L1
jmp top
mov edx, offset msg5
call WriteString
call crlf
main ENDP
end main
Write a program that reads an integer which is an index of one array and copies elements of that array to another array. Your program output should be similar to the sample run/output below.
Declare two arrays which have five 8-bit elements each.
Define a 8-bit data label named startIndex.
Read an integer from the keyboard and save it in the data label defined above.
Create the following procedures in the program:main – Gets user input and calls other procedures
displayTitle – Prints this project title
copyArray – Copies elements from one array to another
showArray – Displays array contents on the console
endProgram – Prints the termination message
Use LOOP, JMP, and conditional jump instructions in the program.
Use indexed addressing to copy one array to another array starting from the entered index.
Use the following operators and directives in the program: PTR, LENGTHOF, $, ALIGN, and OFFSET.
Use the following arrays for your test program: {1, 2, 3, 4, 5} and {0, 0, 0, 0, 0}.
Use the Irvine32 library for this solution program.

Do you need any assistance with this question?
Send us your paper details now
We’ll find the best professional writer for you!

"We offer the best custom paper writing services. We have done this question before we can also do it for you."

  • 100% non-plagiarized Papers
  • 24/7 /365 Service Available
  • Affordable Prices
  • Any Paper, Urgency, and Subject
  • Will complete your papers in 6 hours
  • On-time Delivery
  • Money-back and Privacy guarantees
  • Unlimited Amendments upon request
  • Satisfaction guarantee

Our Service Charter

1. Professional & Expert Writers: Experts Essays only hires the best. Our writers are specially selected and recruited, after which they undergo further training to perfect their skills for specialization purposes. Moreover, our writers are holders of masters and Ph.D. degrees. They have impressive academic records, besides being native English speakers.

2. Top Quality Papers: Our customers are always guaranteed of papers that exceed their expectations. All our writers have +5 years of experience. This implies that all papers are written by individuals who are experts in their fields. In addition, the quality team reviews all the papers before sending them to the customers.

3. Plagiarism-Free Papers: All papers provided by Experts Essays are written from scratch. Appropriate referencing and citation of key information are followed. Plagiarism checkers are used by the Quality assurance team and our editors just to double-check that there are no instances of plagiarism.

4. Timely Delivery: Time wasted is equivalent to a failed dedication and commitment. Experts Essays are known for the timely delivery of any pending customer orders. Customers are well informed of the progress of their papers to ensure they keep track of what the writer is providing before the final draft is sent for grading.

5. Affordable Prices: Our prices are fairly structured to fit in all groups. Any customer willing to place their assignments with us can do so at very affordable prices. In addition, our customers enjoy regular discounts and bonuses.

6. 24/7 Customer Support: At Experts Essays, we have put in place a team of experts who answer all customer inquiries promptly. The best part is the ever-availability of the team. Customers can make inquiries anytime.