Ask Question, Ask an Expert

+61-413 786 465

info@mywordsolution.com

Ask Computer Engineering Expert

Program

The IRS allows a taxpayer to contribute to a ROTH IRA, if his/her income is not over a specified limit and his/her filing status allows contributions.

You will write a program that carries out the logic of a simplified worksheet to determine how much may be contributed to a ROTH IRA.

Sample IRS-like instructions for each line of the worksheet: This worksheet may not be used by any taxpayer who is married filing separately, and did not live with their spouse any time during the year.

Line 1 Determine maximum possible ROTH IRA contribution limit.

If under age 50, enter $5,500 on line 1. Otherwise, enter $6,500 on line 1.

Line 2 Enter the modified Adjusted Gross Income for IRA purposes on line 2.

Line 3 Determine the Income Limit amount for full contributions, according the filing status from the list below and enter limit on line 3:

Single or Head of household - $ 112,000

Married filing jointly or Qualifying Widow(er) - $ 178,000

Married filing separately and lived with spouse any time during year - $ 0

Line 4 Determine if a reduction to the contribution limit is necessary.

Is the amount on line 2 less than or equal to the amount on line 3?

Yes. Can contribute up to maximum contribution limit. Skip lines 4 - 8 and enter the amount from line 1 on line 9 (ignore line 9 instructions) No. Contribution limit may be reduced. Subtract line 3 from line 2 and enter the amount on line 4 and continue.

Line 5 Determine division amount to use, depending on filing status, and enter it on line 5:

Single or Head of household - $ 15,000

Married filing jointly or separately, or Qualifying Widow(er) - $ 10,000

Line 6 Determine reduction percentage.

Divide line 4 by line 5 and determine the floating point result rounded to 3 places. Is the result is 1.0 or more?

Yes. Cannot contribute to a ROTH IRA.

Skip lines 6 - 8 and enter 0 on line 9 (ignore line 9 instructions)

No. Contribution limit will be reduced.

Enter the calculated reduction percentage rounded to 3 places on line 6.

Line 7 Determine reduction amount.

Multiply line 6 by line 1 and enter the result on line 7

Line 8 Determine possible contribution limit.

Subtract line 7 from line 1. Round the result up to the nearest $10, and enter result on line 8

Line 9 Enter the larger value: line 8 or $200.

This line 9 amount is your ROTH IRA contribution limit.

• Determine if the taxpayer should continue, or if the program should exit.

o If the taxpayer's filing status is married filing separately

o Ask if the taxpayer lived with his/her spouse at any time during the year.

(User input can be in either upper or lowercase.)

If the answer is no, the taxpayer may not contribute to a ROTH IRA. contribution.§

Display a message saying so (see Sample 2 Output below) and pause.§

Then return from main with exit code of 1, to indicate that the program returned before line 1.§

return 1;§

o If the program did not exit, continue.

• Read and store the taxpayer's age.

• Perform a test to determine and store the amount for line 1.

• Read and store Adjusted Gross Income for IRA purposes for line 2.

• Determine the line 3 income limit that applies for the filing status entered, and store the result.

o HINT: Store the filing status description in words into a string variable at the same time.

• Display the Worksheet title and the first 3 lines (1 - 3) of the worksheet.

• Perform the line 4 test to determine if the program needs to continue.

o If line 2 is less than or equal to line 3

Display the amount from line 1 on line 9, and pause.§

Then return from main with exit code of 4, to indicate that the program exited on line 4.§

return 4;§

o If the program did not exit, continue.

• Perform the necessary calculation for line 4 and store the result.

• Determine the line 5 division amount to use for the filing status entered, and store it.

• Display lines (4 and 5) of the worksheet.

• Perform the necessary calculation for line 6 and store the result.

Perform the line 6 test to determine if the program needs to continue.

If the result is 1.0 or more, taxpayer cannot contribute to a ROTH IRA:

Display a message, and pause (see Sample 4 output)§

Then return from main with exit code of 4, to indicate that the program exited on line 6.§

return 6;§

o If the program did not exit, continue.

ROTH IRA Contribution Limit Worksheet

Filing Status: Married, Filing Jointly

1. Possible contribution limit: 5500.00

2. Adjusted Gross Income 180330.00

3. Income Limit: 178000.00

4. Amount over Limit: 2330.00

5. Division amount: 10000.00

6. Reduction Percentage: 0.233

7. Reduction Amount: 1281.50

8. Reduced contribution limit: 4220.00

9. Maximum ROTH IRA Contribution Limit 4220.00

Computer Engineering, Engineering

  • Category:- Computer Engineering
  • Reference No.:- M92020917
  • Price:- $40

Priced at Now at $40, Verified Solution

Have any Question?


Related Questions in Computer Engineering

Research ways that information systems have been misused

Research ways that Information Systems have been misused. Using the Internet, find an example of an organization that has misused Information Systems. Post your response to the discussion board. Respond to the following ...

A population has a mean72 and a standard deviation sigma28

A population has a mean=72 and a standard deviation σ=28. Find the mean and standard deviation of a sampling distribution of sample means with sample size n=49.

The standard bcd-to-7-segment decoder such as the 74ls47

The standard BCD-to-7-segment decoder (such as the 74LS47 used in the lab), has active-LOW outputs. Should the 7-segment display be common-anode or common-cathode? Why do you think the decoder is configured for active-LO ...

Penetration testing is a technique used to identify

Penetration testing is a technique used to identify security weaknesses in your network. Discuss a type of penetration testing and the different methods utilized to recognize vulnerabilities in your network.

Answer as thorough as possiblecase 2 describe in detail

Answer as thorough as possible. Case 2: Describe in detail each of four risk factors of holding a domestic bond. Your summary should convince the reader that you fully understand each risk factor.

Many high school students take the ap tests in different

Many high school students take the AP tests in different subject areas. In 2007, of the 144,796 students who took the biology exam 84,199 of them were female. In that same year, of the 211,693 students who took the calcu ...

Hayley motorcycle company just paid a dividend of 14 today

Hayley Motorcycle Company just paid a dividend of $1.4 today, and is expected to pay a dividend in year 1 of $1.8, a dividend in year 2 of $2.3, a dividend in year 3 of $2.9, and a dividend in year 4 of $3.8. After year ...

Arectangular box without a top has surface area 2500 cm2

A rectangular box without a top has surface area 2500 cm2 . The length x of its base is 18 cm longer that its width. (a) Use MATLAB's polynomial functions to express the volume V of the box in terms of x. (b) Plot V vs x ...

How do you calculate the annual interest rate of 12

How do you calculate the annual interest rate of 12% compounded monthly. I know how to do for annually but not monthly. You are offered the opportunity to put some money away for retirement. You will receive 10 annual pa ...

Question sally averages 5 strokes a hole when she plays

Question: Sally averages 5 strokes a hole when she plays golf. One day, she took 40 strokes to complete the first nine holes. Her partner conjectured that she would probably regress to the mean and take 50 strokes to com ...

  • 4,153,160 Questions Asked
  • 13,132 Experts
  • 2,558,936 Questions Answered

Ask Experts for help!!

Looking for Assignment Help?

Start excelling in your Courses, Get help with Assignment

Write us your full requirement for evaluation and you will receive response within 20 minutes turnaround time.

Ask Now Help with Problems, Get a Best Answer

Why might a bank avoid the use of interest rate swaps even

Why might a bank avoid the use of interest rate swaps, even when the institution is exposed to significant interest rate

Describe the difference between zero coupon bonds and

Describe the difference between zero coupon bonds and coupon bonds. Under what conditions will a coupon bond sell at a p

Compute the present value of an annuity of 880 per year

Compute the present value of an annuity of $ 880 per year for 16 years, given a discount rate of 6 percent per annum. As

Compute the present value of an 1150 payment made in ten

Compute the present value of an $1,150 payment made in ten years when the discount rate is 12 percent. (Do not round int

Compute the present value of an annuity of 699 per year

Compute the present value of an annuity of $ 699 per year for 19 years, given a discount rate of 6 percent per annum. As