Create a program to predict the amount of money

Assignment Help Python Programming
Reference no: EM132360802

The assignment is to create a program to predict the amount of money you will have in your IRA when you retire. Inputs are:

1. Number of years until you retire, it must be a whole number (integer) in the range 1 to 70. Any number outside of this range is to be rejected and the user will be required to enter the value again, this repeat must be done until a valid number is input.

2. Expected interest rate as a percent (this the average expected earnings per year until retirement is reached). The number must be 0 or greater, any other value will be rejected and as above, the user must be polled until a valid number is input. If the number is greater than 10%, the user must be asked if he/she really expects to earn this much, if the user replies in the affirmative, the number is to be used, otherwise the user will be asked to input the value again and the above checks will be made.

3. The initial amount in the IRA. This is a decimal number and may be any non-negative number. If a negative number is entered, the value is to be rejected and the user will be required to enter an acceptable value. Again, loop until a valid value is input.

4. The amount expected to be added to the IRA each year. This is a decimal number in the range of 0 to $2,500. The program must loop asking for this value until a valid value is entered.

After the data is input and validated, the program is to loop printing out the value of the IRA every 5 years and the value at the end of the time entered as input #1. The value is to be computed in a loop where the value each year is determined by:

value = value + (value)*rate + yearlyInput

Remember the rate in the above equation is the rate entered in #2 above divided by 100, the decimal equivalent of the percentage.

Make certain to test your program before you have me check it. You can count on me entering bad values to be certain they are rejected. Also make sure that the amounts that your program compute are valid! You can do some testing by having an interest rate of 0% to verify the yearly addition is handled correctly. You can use an interest rate of 10% to validate one year's interest rate. You can print out the value every year while debugging and then put in the 5 year print later. A while loop while probably be handy for you input validation.

Reference no: EM132360802

Questions Cloud

Write a class named animal with the following attributes : InfoTc 1040 Introduction to Problem Solving and Programming-Write a class named Animal with the following attributes and methods.
Improving the well-being of consumers : What are Walmart's contributions to improving the well-being of consumers and the economic sustainability of society?
Types of social media : Construct a 10 min. Power Point Presentation outline how it can benefit the company by using various types of social media through big data.
Yourself doubting your own ability to accomplish goal : Have you ever found yourself doubting your own ability to accomplish a goal? If so, which goal?
Create a program to predict the amount of money : Create a program to predict the amount of money you will have in your IRA when you retire. Number of years until you retire, it must be a whole number.
Your score accurately reflects your locus of control at work : Do you think that your score accurately reflects your locus of control at work? Why or why not? What do you think is ideal locus of control in a work setting
What will you do to motivate them : Your Project Sponsor and customer informed you that you have to deliver your project much sooner than anticipated. When you break the news to your team
People and organizational leaders during hurricane : How devastating was 'Hurricane Andrew' in 2002? What ethical issues were faced during this period?
Takes a list of integers as input and returns true : Write function arithmetic() that takes a list of integers as input and returns True if they form an arithmetic sequence.

Reviews

Write a Review

Python Programming Questions & Answers

  Write a python program to implement the diff command

Without using the system() function to call any bash commands, write a python program that will implement a simple version of the diff command.

  Write a program for checking a circle

Write a program for checking a circle program must either print "is a circle: YES" or "is a circle: NO", appropriately.

  Prepare a python program

Prepare a Python program which evaluates how many stuck numbers there are in a range of integers. The range will be input as two command-line arguments.

  Python atm program to enter account number

Write a simple Python ATM program. Ask user to enter their account number, and print their initail balance. (Just make one up). Ask them if they wish to make deposit or withdrawal.

  Python function to calculate two roots

Write a Python function main() to calculate two roots. You must input a,b and c from keyboard, and then print two roots. Suppose the discriminant D= b2-4ac is positive.

  Design program that asks user to enter amount in python

IN Python Design a program that asks the user to enter the amount that he or she has budget in a month. A loop should then prompt the user to enter his or her expenses for the month.

  Write python program which imports three dictionaries

Write a Python program called hours.py which imports three dictionaries, and uses the data in them to calculate how many hours each person has spent in the lab.

  Write python program to create factors of numbers

Write down a python program which takes two numbers and creates the factors of both numbers and displays the greatest common factor.

  Email spam filter

Analyze the emails and predict whether the mail is a spam or not a spam - Create a training file and copy the text of several mails and spams in to it And create a test set identical to the training set but with different examples.

  Improve the readability and structural design of the code

Improve the readability and structural design of the code by improving the function names, variables, and loops, as well as whitespace. Move functions close to related functions or blocks of code related to your organised code.

  Create a simple and responsive gui

Please use primarily PHP or Python to solve the exercise and create a simple and responsive GUI, using HTML, CSS and JavaScript.Do not use a database.

  The program is to print the time

The program is to print the time in seconds that the iterative version takes, the time in seconds that the recursive version takes, and the difference between the times.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd