Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Write an Assembly program that prints an ASCII art version of a right triangle to the screen. For example, for size 5, we would get:
Write an Assembly program that prints an ASCII art version of a right triangle to the screen. For example, for size 5, we would get: USE THIS CODE AS AREFERENCE! data ropt BYTE" count DHORD s dword x dword? size of triangie to dra: ,0 size of triangle aumber of SPACEs to print nurber of 'x's to print .code ain proc mov edx, offset prompt call KriteString call ReadDec put adare3s of propt tring into EDX - or WriteString Write string starting at EDX :read from keyboard into EAX or ecx,count:counter for oute loop 2:inner loop mor al, '.'; write space.s call riteChar oop 12 : repeat the inner loop L3: mor al, 'x' 2nd int loop call Kritechar wite spaces loop 13 oop repeat the outer Loop Write an Assembly program that prints an ASCII art version of a right triangle to the screen. For example, for size 5, we would get: USE THIS CODE AS AREFERENCE! data ropt BYTE" count DHORD s dword x dword? size of triangie to dra: ,0 size of triangle aumber of SPACEs to print nurber of 'x's to print .code ain proc mov edx, offset prompt call KriteString call ReadDec put adare3s of propt tring into EDX - or WriteString Write string starting at EDX :read from keyboard into EAX or ecx,count:counter for oute loop 2:inner loop mor al, '.'; write space.s call riteChar oop 12 : repeat the inner loop L3: mor al, 'x' 2nd int loop call Kritechar wite spaces loop 13 oop repeat the outer Loop
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started