Welcome to the Investment Challenge, a terminal-based game that helps you simulate investments and understand the power of compound interest. In this game, you'll be tasked with growing your investment over time and achieving your financial goals.
- Author Name: MD Riad Khan RK
- Author Brand: RK Studio
- GitHub: rkstudio585
- Website: rkstudio.com
- Nickname: RK
- Email: [email protected]
- Features
- How It Works
- Math Behind the Game
- How to Use
- How to Run
- How to Download
- License
- Questions
- Acknowledgments
- 🏦 Simulates investment growth over time.
- 📈 Calculates future value based on user input.
- 🎯 Allows users to set investment goals.
- 💡 Interactive terminal-based gameplay.
In this game, players start with an initial investment and specify the nominal interest rate and investment duration. The game calculates how much the investment will grow and whether it meets the player's goals.
The game uses the following financial formulas:
-
Future Value (FV): [ FV = P \times (1 + r/n)^{nt} ] Where:
- ( P ) = Principal amount (initial investment)
- ( r ) = Nominal annual interest rate (as a decimal)
- ( n ) = Number of compounding periods per year
- ( t ) = Number of years
-
Effective Annual Rate (EAR) (if needed for further extensions): [ EAR = (1 + r/n)^{n} - 1 ] This formula helps in understanding the real return on an investment, considering the effect of compounding.
-
Clone this repository:
git clone https://github.com/rkstudio585/investment-challenge.git cd investment-challenge
-
Compile the program using:
gcc investment_game.c interest_calculations.c -o investment_game -lm
-
Run the game:
./investment_game
-
Make sure you have GCC installed on your machine. If not, install it using:
- Ubuntu:
sudo apt install build-essential
- Mac:
xcode-select --install
- Windows: Install MinGW or use WSL.
- Ubuntu:
-
Follow the steps in the How to Use section to compile and run the game.
To download the project from GitHub, you can use the following command in your terminal:
git clone https://github.com/rkstudio585/investment-challenge.git
This command clones the repository to your local machine, allowing you to run and modify the game.
If you have any questions about the project or need assistance, feel free to reach out:
- How to work?
- How I Use?
- Etc..
- Thanks to the open-source community for their valuable contributions.
- Special thanks to all who provide feedback to improve this project.
. . . . . . . . .
. . . . . . . . . . . . .
. . . . . . . . . . . . .
. . . . . . . . . . . . . .
. . . . . . . . . . . . . .
. . . . . . . . . . . .
Enjoy the game and happy investing! 🚀💵