Python Exercises for Corporate Finance and Risk Management

8 / 26

Question: 50

Q: Compute the present value of $1 received after 6-years, if your opportunity cost of capital is 12%.
INSTRUCTIONS
We have to find out the current value of $1 that we will get after 6 years, where opportunity cost is given that is 12%.

 - Define a function called "NPV" in python taking values of cash flow and opportunity cost.
 - Use simple formula of discount cash flow.

Present_value = amount / (pow((1 + rate / 100), time))

Where:
Amount = $1
Rate = 12%
Time = 6 years


Note - Having trouble with the assessment engine? Follow the steps listed here

Loading comments...