Write a windows32 assembly language program in visual studio that utilizes a recursive procedure. The main (_MainProc) procedure should: accept, from the user, an integer greater than 0.  Guard against invalid values being entered using a loop. call the recurse sub-procedure using the cdecl protocol, receive the results of the sub-procedure, and display the results.         NOTE: The main procedure should do nothing more than this! The recurse sub-procedure should (following the cdecl protocol): recursively find the solution for: recurse(0) = 3, and recurse(n) = 5 * recurse(n-1) + 9, for n > 0. return the value back to the calling procedure. Notes:   Both the main procedure and recurse sub-procedure must follow the cdecl protocol.  I need commented code otherwise it will be not accepted

C++ Programming: From Problem Analysis to Program Design
8th Edition
ISBN:9781337102087
Author:D. S. Malik
Publisher:D. S. Malik
Chapter15: Recursion
Section: Chapter Questions
Problem 6PE
icon
Related questions
Topic Video
Question

Write a windows32 assembly language program in visual studio that utilizes a recursive procedure.

The main (_MainProc) procedure should:
  1. accept, from the user, an integer greater than 0.  Guard against invalid values being entered using a loop.
  2. call the recurse sub-procedure using the cdecl protocol,
  3. receive the results of the sub-procedure, and
  4. display the results.

        NOTE: The main procedure should do nothing more than this!

The recurse sub-procedure should (following the cdecl protocol):
  • recursively find the solution for:
    • recurse(0) = 3, and
    • recurse(n) = 5 * recurse(n-1) + 9, for n > 0.
  • return the value back to the calling procedure.

Notes:  

Both the main procedure and recurse sub-procedure must follow the cdecl protocol. 

I need commented code otherwise it will be not accepted

Expert Solution
steps

Step by step

Solved in 2 steps with 1 images

Blurred answer
Knowledge Booster
Instruction Format
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
C++ Programming: From Problem Analysis to Program…
C++ Programming: From Problem Analysis to Program…
Computer Science
ISBN:
9781337102087
Author:
D. S. Malik
Publisher:
Cengage Learning
EBK JAVA PROGRAMMING
EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781337671385
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT
C++ for Engineers and Scientists
C++ for Engineers and Scientists
Computer Science
ISBN:
9781133187844
Author:
Bronson, Gary J.
Publisher:
Course Technology Ptr
Programming with Microsoft Visual Basic 2017
Programming with Microsoft Visual Basic 2017
Computer Science
ISBN:
9781337102124
Author:
Diane Zak
Publisher:
Cengage Learning
Systems Architecture
Systems Architecture
Computer Science
ISBN:
9781305080195
Author:
Stephen D. Burd
Publisher:
Cengage Learning