This repository contains the Investment Growth Calculator project code from my CS 210 course. The project demonstrates my ability to write well-documented and readable C++ code, design functional programs that meet industry standards, and use multiple programming languages to develop secure and efficient code.
The Investment Growth Calculator is designed to help users calculate the year-end balance and earned interest on an initial investment, both with and without additional monthly deposits. The user inputs the initial investment amount, monthly deposit, annual interest rate, and the number of years for the investment. The program then calculates and displays the year-end balances and earned interest for both scenarios.
This project addresses the need for users to understand how their investments will grow with and without regular contributions. It helps in planning and decision-making regarding savings and investments.
I was particularly effective in structuring the program to be modular and readable. I ensured each function had a single responsibility, making the code easier to test and debug. Descriptive variable names and comments throughout the code also added to its readability.
By exploring different algorithms and data structures, I could optimize the calculations to handle larger datasets more efficiently. Expanding the program into a budget and investment application would significantly enhance it. This could include features such as tracking multiple investments, budgeting expenses, forecasting future financial scenarios, and providing detailed reports and visualizations. This would make the program more versatile and valuable for personal finance management.
The most challenging part of the code was ensuring accurate calculations of the monthly and yearly interests, especially when dealing with floating-point arithmetic. I overcame this by thoroughly testing the program with different input values and comparing the results to manual calculations to ensure accuracy. Additionally, online resources such as the SNHU discord and watching a few YouTube videos helped clarify certain concepts and best practices.
Modular programming, code documentation, and problem-solving skills are highly transferable to other projects. The ability to break down a problem into manageable parts and write clean, maintainable code is crucial for any programming task. The experience gained in handling user inputs and performing calculations will be helpful in many other applications.
I made the program maintainable, readable, and adaptable by following best practices in code documentation, using descriptive variable and function names, and structuring the code into logical sections. I also wrote the code so that new features or changes can be easily integrated without requiring extensive modifications to the existing codebase. Commenting on the code and providing clear user instructions further maintained its maintainability.