applesseed
Senior member
Okay... I know I'm an @$$ for asking this assignment for my "Software Development" course (IT course requirement) but I personally never know how to do this kind of stuff. So I'm asking you for your kind help. I'm not asking you to do it for me because that's unfair but rather take a look at my own pseudocode attempt. Give me some feedbacks or guides. Of course if you'd like to write the p-code for me, I'd thankfully appreciated
Requirements:
The user enters the price of the item they want to purchase, the down payment they can afford, the best interest rate they could find, and the number of payments in months (12, 24, 48, 60). When the user clicks the monthly payment button, the program will return to them the amount of the loan and their monthly payments. When the user clicks the total button, the program will return the total they actually paid for their item.
Payment Algorithm:
The monthly payment on a loan may be calculated by the following formula:
Payment Forumula
Rate is the monthly interest rate, which is the annual interest rate divided by 12. N is the number of monthly payments, and L is the amount of the loan.
My attempt:
PROMPT user to enter the price of the item they want to purchase
PROMPT user the down payment they can afford
Prompt user the best interest rate they could find
Prompt user the number of payments in months (12, 24, 48, 60)
GET price of the item
STORE in a variable called L
IF user input is bad THEN
PROMPT user to re-enter price of the item
ELSE DISPLAY Thank you; Please proceed
END IF
GET down payment user can afford
IF user input is bad THEN
PROMPT user to re-enter down payment
ELSE DISPLAY Thank you; Please proceed
END IF
GET best interest user could find
STORE in a variable called R
IF user input is bad THEN
PROMPT user to re-enter best interest rate
ELSE DISPLAY Thank you; Please proceed
END IF
GET the number of payments in months
STORE in a variable called N
IF user input = 12
ELSE IF user input = 24
ELSE IF user input = 48
ELSE IF user input = 60
ELSE incorrect input THEN
PROMPT user to re-enter number of payments in months
END
PROMPT user to click monthly payment button
CALCULATE R multiplied by (1+R) raised to the power of N
divided by (1+R) raised to the power of N minus 1
multiply result by L
DISPLAY amount of loan and monthly payments
END
PROMPT user to click the total button
CALCULATE amount of loan
yadda yadda yadda yadda yadda yadda I don't understand
Requirements:
The user enters the price of the item they want to purchase, the down payment they can afford, the best interest rate they could find, and the number of payments in months (12, 24, 48, 60). When the user clicks the monthly payment button, the program will return to them the amount of the loan and their monthly payments. When the user clicks the total button, the program will return the total they actually paid for their item.
Payment Algorithm:
The monthly payment on a loan may be calculated by the following formula:
Payment Forumula
Rate is the monthly interest rate, which is the annual interest rate divided by 12. N is the number of monthly payments, and L is the amount of the loan.
My attempt:
PROMPT user to enter the price of the item they want to purchase
PROMPT user the down payment they can afford
Prompt user the best interest rate they could find
Prompt user the number of payments in months (12, 24, 48, 60)
GET price of the item
STORE in a variable called L
IF user input is bad THEN
PROMPT user to re-enter price of the item
ELSE DISPLAY Thank you; Please proceed
END IF
GET down payment user can afford
IF user input is bad THEN
PROMPT user to re-enter down payment
ELSE DISPLAY Thank you; Please proceed
END IF
GET best interest user could find
STORE in a variable called R
IF user input is bad THEN
PROMPT user to re-enter best interest rate
ELSE DISPLAY Thank you; Please proceed
END IF
GET the number of payments in months
STORE in a variable called N
IF user input = 12
ELSE IF user input = 24
ELSE IF user input = 48
ELSE IF user input = 60
ELSE incorrect input THEN
PROMPT user to re-enter number of payments in months
END
PROMPT user to click monthly payment button
CALCULATE R multiplied by (1+R) raised to the power of N
divided by (1+R) raised to the power of N minus 1
multiply result by L
DISPLAY amount of loan and monthly payments
END
PROMPT user to click the total button
CALCULATE amount of loan
yadda yadda yadda yadda yadda yadda I don't understand