Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

A non-governmental organization needs a program to calculate the amount of finan

ID: 3703270 • Letter: A

Question

A non-governmental organization needs a program to calculate the amount of financial assistance for needy families. The formula is as follows:

If the annual household income is between $30,000 and $40,000 and the household has at least three children, the amount is $1,000 per child.

If the annual household income is between $20,000 and $30,000 and the household has at least two children, the amount is $1,500 per child.

If the annual household income is less than $20,000, the amount is $2,000 per child.

Create the pseudocode for the following: Implement 1 method for the above. Then in main, write a program that asks the user for their household income and number of children, then prints the calculated financial assistance amount returned by your method.

Explanation / Answer

method: assist(income, children)

if(income>=30000 and income<=40000 and children >=3

return children*1000

if(income>=20000 and income<=30000 and children >=2

return children*1500

if(income<=20000

return children*2000

end of assit method

main:

income = input("Enter your houshold income: ")

children = input("Enter the number of children: ")

print("Financial amount = ", assit(income, children)

end of main

Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote