Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Anon-govemmental organization needs a program to calculate the amount of financial assistance for needy families. The formula is as follows: if the annuat household income

image text in transcribed
Anon-govemmental organization needs a program to calculate the amount of financial assistance for needy families. The formula is as follows: if the annuat 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 Write a function for this computation. Write a program that asks for the household income and number of children for each applicant, printing the amount returned by your function. Use-1 as a sentinel value for the input Sample Run: What is the household income (-1 to quit)? 35000 How many children? 3 The assistance amount is $3000.00 What is the household income (-1 to quit)? 50000 How many children? 2 The assistance amount is $0.00 What is the household income (-1 to quit)? -1 Anon-govemmental organization needs a program to calculate the amount of financial assistance for needy families. The formula is as follows: if the annuat 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 Write a function for this computation. Write a program that asks for the household income and number of children for each applicant, printing the amount returned by your function. Use-1 as a sentinel value for the input Sample Run: What is the household income (-1 to quit)? 35000 How many children? 3 The assistance amount is $3000.00 What is the household income (-1 to quit)? 50000 How many children? 2 The assistance amount is $0.00 What is the household income (-1 to quit)? -1

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Modeling And Design

Authors: Toby J. Teorey, Sam S. Lightstone, Tom Nadeau, H.V. Jagadish

5th Edition

0123820200, 978-0123820204

More Books

Students also viewed these Databases questions