Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

i . Develop an initial decomposition of the problem using the chevron notation ( > and > > ) from the module materials. Include your

i.Develop an initial decomposition of the problem using the chevron notation (> and >>) from the module materials. Include your initial decomposition in your solution document.
ii.Building on your initial decomposition for part (c)(i), develop an algorithm for solving the problem. Include this algorithm in your solution document, and also write down your PI and the individual number that you have obtained via Steps 13 from your PI.
iii.Write a Python function definition following the instructions that are provided below.
Important note: in order to raise a quantity to a power, the Python operator ** can be used. So, for example, 2**3 is evaluated as .
Write a single Python function that implements the algorithm you wrote for part (c)(ii). Your function must be a translation of your algorithm from part (c)(ii), otherwise no marks will be awarded.
The function should have three arguments: one for the future savings, future_savings, one for the annual interest rate, annual_interest_rate, and a third for the number of years, nb_years, that the money will grow.
The function should have one return value for the recommended amount needed to deposit, estimated_deposit, which is a double (rounded to two decimal places).
Save your function in a file called Q4_OUCU.py, where OUCU is your OU computer username, e.g. abc123.
When you have completed your work on this part:
paste the function definition from your code file into your solution document as text (with indentation preserved) using an evenly spaced font such Courier New or Consolas
include the code file with your function in your TMA zip file.
iv.Test the function by calling it with the arguments 20000,0.05 and 8 in your Python program. Paste the function call and the result as text into your solution document.
You should aim to use only the Python features that are introduced in the module. If you decide to use techniques or language features that TM112 does not cover, you must give a justification for your decisions, otherwise marks will be lost.

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 Programming With Visual Basic .NET

Authors: Carsten Thomsen

2nd Edition

1590590325, 978-1590590324

More Books

Students also viewed these Databases questions