// A standard mortgage is paid monthly over 30 years. // This program is intended to display 360 payment coupons // for a new borrower. Each coupon lists the month number, // year number, and a friendly mailing reminder.

Microsoft Visual C#
7th Edition
ISBN:9781337102100
Author:Joyce, Farrell.
Publisher:Joyce, Farrell.
Chapter5: Looping
Section: Chapter Questions
Problem 2CP
icon
Related questions
Question

// A standard mortgage is paid monthly over 30 years.

// This program is intended to display 360 payment coupons

// for a new borrower. Each coupon lists the month number,

// year number, and a friendly mailing reminder.

start

   num MONTHS = 12

   num YEARS = 30

   string MSG = "Remember to allow 5 days for mailing"

   num monthCounter = 0

   num yearCounter = 30

    while yearCounter <= YEARS

       while monthCounter <= MONTHS

         output monthCounter, yearCounter, MSG

      endwhile

   endwhile

stop

 

housekeeping()

   print "Enter account number or ", QUIT, " to quit "

return

 

printCoupons()

   while yearCounter <= YEARS

      while monthCounter <= MONTHS

         print acctNum, monthCounter, yearCounter, MSG

         monthCounter = monthCounter + 1

      endwhile

      yearCounter = yearCounter + 1

   endwhile

   output "Enter account number or ", QUIT, " to quit "

   input acctNum

return

 

finish()

   output "End of job"

return

// A standard mortgage is paid monthly over 30 years.
// This program is intended to print 360 payment coupons
// for each new borrower at a mortgage comapny. Each coupon
// lists the month number, year number, and a friendly mailing reminder.
start
Declarations
num MONTHS = 12
num YEARS = 360
string MSG = "Remember to allow 5 days for mailing"
num acctNum
num monthCounter
num yearCounter
housekeeping ()
while acctNUm <> QUIT
printCoupons ()
endwhile
finish()
stop
housekeeping()
print "Enter account number or ", QUIT,
to quit "
return
printCoupons ()
while yearCounter <= YEARS
while monthCounter <= MONTHS
print acctNum, monthCounter, yearCounter, MSG
monthCounter = monthCounter + 1
endwhile
yearCounter + 1
yearCounter
endwhile
output "Enter account number or ", QUIT,
input acctNum
to quit
return
finish()
output "End of job"
return
Transcribed Image Text:// A standard mortgage is paid monthly over 30 years. // This program is intended to print 360 payment coupons // for each new borrower at a mortgage comapny. Each coupon // lists the month number, year number, and a friendly mailing reminder. start Declarations num MONTHS = 12 num YEARS = 360 string MSG = "Remember to allow 5 days for mailing" num acctNum num monthCounter num yearCounter housekeeping () while acctNUm <> QUIT printCoupons () endwhile finish() stop housekeeping() print "Enter account number or ", QUIT, to quit " return printCoupons () while yearCounter <= YEARS while monthCounter <= MONTHS print acctNum, monthCounter, yearCounter, MSG monthCounter = monthCounter + 1 endwhile yearCounter + 1 yearCounter endwhile output "Enter account number or ", QUIT, input acctNum to quit return finish() output "End of job" return
Chapter 4 Debug 2
II A standard mortgage is paid monthly over 30 years.
I/ This program is intended to display 360 payment coupons
Il for a new borrower. Each coupon lists the month number,
Il year number, and a friendly mailing reminder.
start
num MONTHS = 12
num YEARS = 30
string MSG = "Remember to allow 5 days for mailing"
num monthCounter = 0
num yearCounter = 30
while yearCounter <= YEARS
while monthCounter <= MONTHS
output monthCounter, yearCounter, MSG
endwhile
endwhile
stop
housekeeping()
print "Enter account number or ", QUIT, " to quit "
return
Transcribed Image Text:Chapter 4 Debug 2 II A standard mortgage is paid monthly over 30 years. I/ This program is intended to display 360 payment coupons Il for a new borrower. Each coupon lists the month number, Il year number, and a friendly mailing reminder. start num MONTHS = 12 num YEARS = 30 string MSG = "Remember to allow 5 days for mailing" num monthCounter = 0 num yearCounter = 30 while yearCounter <= YEARS while monthCounter <= MONTHS output monthCounter, yearCounter, MSG endwhile endwhile stop housekeeping() print "Enter account number or ", QUIT, " to quit " return
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 2 steps

Blurred answer
Knowledge Booster
ListBox
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
Microsoft Visual C#
Microsoft Visual C#
Computer Science
ISBN:
9781337102100
Author:
Joyce, Farrell.
Publisher:
Cengage Learning,
Programming with Microsoft Visual Basic 2017
Programming with Microsoft Visual Basic 2017
Computer Science
ISBN:
9781337102124
Author:
Diane Zak
Publisher:
Cengage Learning
Programming Logic & Design Comprehensive
Programming Logic & Design Comprehensive
Computer Science
ISBN:
9781337669405
Author:
FARRELL
Publisher:
Cengage
EBK JAVA PROGRAMMING
EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781305480537
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT
EBK JAVA PROGRAMMING
EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781337671385
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT