Question: for S... The... C Sear N COM. GitHub 3.2 Child Tax Credit When filing for federal taxes, a credit is given to tax payers with


for S... The... C Sear N COM. GitHub 3.2 Child Tax Credit When filing for federal taxes, a credit is given to tax payers with dependent children according to the following rules. The first dependent child younger than 18 is worth a $1,000.00 credit. Each dependent child younger than 18 after the first child is worth a $500 tax credit each. You will complete a Java program to output a table of dependent children, how much each contributes to a tax credit, and a total child tax credit. Your table should look something like the following. Child Tommy (14) Richard (12) Harold (21) Total Credit: Amount $1000.00 $500.00 $0.00 $1500.00 1. Open the Child.java and ChildCredit.java source files 2. The Child class has already been implemented for you. Note how the Child class is used. Several instances of children have been created and places into a List. Similar to an array, a List stores elements using O-indexing. Each one can be accessed using the get method. For example, kids.get(i) gets the i-th kid. You could also use an enhanced for loop to iterate over the elements in the List. 3. Implement the produceReport method to compute the child tax credit(s) and output a table similar to the one above. Your method should return the grand total of the credit. Each child is an instance of the Child class. Each instance has its own variables so that each child can be a different age. To get a particular child's age, you can use a getter method. For example, to get the age of tom you can use the syntax, ton.getAge() ty MacBook A * I * I NON 3.EE 2 Natural.java Child.java Child Credit.java 1 backage unl.cse; 2 30 import java.util.ArrayList;/ 5 7 * This program produces a report on how much a a tax payer can expect for their 8 * child tax credits. 9 10 * @author skaucke 11 * 12 */ 13 public class ChildCredit { 14 150 /** 16 * Produces a report (printed to the standard output) of how much 17 * of a credit each child receives as well as a grand total. 18 19 * Returns the total child tax credit. 20 21 * @paran kids 22 * @return 23 240 public static int produceReport(List
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
