From 372962d3ab02a15ee143919f0418680bf872ebe0 Mon Sep 17 00:00:00 2001 From: Sh1vam <70308097+Sh1vam@users.noreply.github.com> Date: Mon, 6 Jan 2025 12:43:09 +0530 Subject: [PATCH 1/2] Update simple-interest.sh --- simple-interest.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/simple-interest.sh b/simple-interest.sh index 27a60fcb55..7dcf830106 100755 --- a/simple-interest.sh +++ b/simple-interest.sh @@ -4,7 +4,7 @@ # Author: Upkar Lidder (IBM) # Addtional Authors: -# +# Sh1vam # Input: # p, principal amount From 08ed08d00a54d930f870b6a9cfc4517b39048631 Mon Sep 17 00:00:00 2001 From: Sh1vam <70308097+Sh1vam@users.noreply.github.com> Date: Mon, 6 Jan 2025 12:48:04 +0530 Subject: [PATCH 2/2] Update compound_interest.py --- compound_interest.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/compound_interest.py b/compound_interest.py index 9673a7a029..acaccf54a5 100755 --- a/compound_interest.py +++ b/compound_interest.py @@ -15,7 +15,9 @@ def compound_interest(p, t, r): return p * (pow((1 + r / 100), t)) - +def compound_interest_equivalent(p, t, r): + return p * (((1 + r) / 100))**t)) + if __name__ == "__main__": p = float(input("Enter the principal amount: ")) t = float(input("Enter the time period: "))