Mid-level 13 min · March 06, 2026

Simple vs Compound Interest — Daily Cost ₹21k

Credit cards compound daily: 36% APR becomes 43.3% effective.

N
Naren Founder & Principal Engineer

20+ years shipping production code across the stack, with years spent interviewing engineers. Written from production experience, not tutorials.

Follow
Production
production tested
May 23, 2026
last updated
1,554
articles · all by Naren
 ● Production Incident 🔎 Debug Guide ⚙ Triage Commands
Quick Answer
  • Simple Interest (SI): fixed yearly interest on original principal only
  • Compound Interest (CI): interest on interest, exponential growth over time
  • Core formulas: SI = (P×R×T)/100 ; A = P×(1+R/100)^T
  • 2-year shortcut: CI − SI = P×(R/100)² saves 30 seconds in exams
  • More frequent compounding = higher effective rate (EAR)
  • Rule of 72: years to double ≈ 72 / rate (valid 6–10%)
✦ Definition~90s read
What is Simple and Compound Interest?

Simple interest is a method of calculating the interest charge on a principal amount where the interest earned or paid is computed solely on the original principal, without compounding. It is defined by the formula I = P r t, where I is interest, P is principal, r is the annual interest rate, and t is time in years.

Imagine you lend your friend ₹1,000 and he agrees to pay you back with a little extra each year as a 'thank you' fee — that extra is called interest.

Compound interest, in contrast, calculates interest on both the initial principal and the accumulated interest from previous periods, effectively earning 'interest on interest.' Its formula is A = P (1 + r/n)^(nt), where n is the number of compounding periods per year. The key distinction is that simple interest grows linearly, while compound interest grows exponentially over time.

This distinction exists because financial systems need to model the time value of money accurately. Simple interest is used for short-term loans, bonds, or situations where compounding is not applied, such as some consumer loans or car financing. Compound interest is fundamental to savings accounts, mortgages, credit cards, and long-term investments, as it reflects the real-world effect of reinvesting earnings.

The choice between them directly impacts total cost or return, making it critical for financial planning and debt management.

In the broader context of finance and mathematics, simple vs compound interest sits at the core of time value of money concepts. It is a foundational topic in personal finance, corporate finance, and actuarial science, influencing decisions from loan comparisons to retirement savings.

Understanding this difference allows individuals and institutions to evaluate the true cost of borrowing or the growth potential of investments, ensuring informed financial choices.

Plain-English First

Imagine you lend your friend ₹1,000 and he agrees to pay you back with a little extra each year as a 'thank you' fee — that extra is called interest. Simple Interest is like charging that same fixed fee every year on just the original amount. Compound Interest is like charging the fee on the original amount PLUS all the fees he already owed you — so the debt snowballs over time. Banks use Simple Interest for short-term loans and Compound Interest for savings accounts and long-term loans, which is exactly why your savings account grows faster than you expect.

Here's a real-world way to feel the difference. Two friends — Sameer and Priya — each invest ₹1,00,000 at 10% per year for 20 years. Sameer picks a Simple Interest scheme. Priya picks Compound Interest. After 20 years, Sameer has ₹3,00,000. Priya has ₹6,72,750. Sameer earned ₹2,00,000 in interest. Priya earned ₹5,72,750 — almost three times more — on the exact same principal and rate. That gap is the snowball. That's why every bank, every loan, and every investment product on earth is built on one of these two formulas.

Money doesn't just sit still — it grows. Whether you're taking a home loan, investing in a fixed deposit, or just trying to understand why your credit card bill seems to balloon, the engine behind all of it is interest. Simple and Compound Interest are two of the most fundamental concepts in finance, and they show up in every banking exam, aptitude round, and technical interview that touches quantitative reasoning.

The problem most people face is that these formulas look like abstract math with no grounding in reality. So they memorise, forget, and then panic in an exam room. This article fixes that. Every formula here is tied to a story you can picture, and every trick is one that saves you real seconds in a timed aptitude test.

I'll be honest — I used to think interest calculations were boring textbook filler until I took my first home loan. The bank quoted me 8.5% per annum. Sounds reasonable, right? Over 20 years on a ₹40 lakh loan, that 8.5% compounded monthly means I'd pay ₹82 lakh total — more than double what I borrowed. The bank earns ₹42 lakh in interest from me. That's when I realised these formulas aren't academic exercises. They're the arithmetic of every financial decision you'll ever make.

By the end of this article you'll be able to calculate Simple and Compound Interest from scratch, spot which formula to use in a word problem in under five seconds, understand the Effective Annual Rate that banks don't advertise, avoid the classic mistakes that cost candidates marks, and answer the tricky follow-up questions interviewers love to throw at confident-sounding candidates.

What Is Simple Interest — And Why Does It Even Exist?

Think of Simple Interest as a rental fee for money. You borrow someone's money for a fixed period, and you pay a fixed percentage of the original amount (called the Principal) as a fee for each year you hold it. The word 'Simple' is literal — the interest is always calculated on the same original amount, no matter how many years pass.

The three ingredients you always need are: • Principal (P) — the original amount borrowed or invested. • Rate (R) — the percentage charged per year, like 5% or 10%. • Time (T) — how long the money is borrowed, in years.

Simple Interest (SI) = (P × R × T) / 100

Total Amount returned = P + SI

Where does this come from? If the rate is 10% per year, then for one year you owe 10/100 of P. For two years you owe twice that. For T years you owe T × (R/100) × P. That's it. No hidden magic.

Simple Interest is used in short-term personal loans, auto loans, and most aptitude exam problems because it's predictable and easy to verify. It's the baseline every finance concept is built on.

In the real world, you'll encounter SI mostly in short-duration lending. Car loans in India (under 5 years) often use SI. Some personal loan apps advertise 'flat rate' interest — that's SI by another name. The reason it works for short terms: the interest-on-interest effect is negligible over 1-3 years, so SI and CI produce nearly identical results. But stretch it to 10+ years and the gap becomes enormous.

Here's something most textbooks won't tell you: flat rate loans are deliberately confusing. A lender says '8% flat rate' on a car loan, which sounds low. But because you repay principal every month, the effective interest rate is roughly double that. Always ask: 'Is this flat rate or reducing balance?' If it's flat, convert it mentally: for a 5-year loan, the reducing balance equivalent is about 1.8 × the flat rate. So 8% flat ≈ 14.4% actual. That's a huge difference.

io/thecodeforge/interest/SimpleInterestCalculator.javaJAVA
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
package io.thecodeforge.interest;

/**
 * io.thecodeforge: Simple Interest Calculator
 * Covers direct calculation, reverse engineering, and year-by-year breakdown.
 */
public class SimpleInterestCalculator {\n\n    /**\n     * Calculates Simple Interest.\n     *\n     * Formula: SI = (Principal × Rate × Time) / 100\n     *\n     * @param principal   The original sum of money (in any currency unit)\n     * @param ratePerYear The annual interest rate as a percentage (e.g., 5 for 5%)\n     * @param timeInYears How long the money is borrowed or invested (in years)\n     * @return The simple interest earned or owed\n     */\n    public static double calculateSimpleInterest(\n            double principal,\n            double ratePerYear,\n            double timeInYears) {\n\n        // Core formula: divide by 100 because rate is given as a percentage\n        double simpleInterest = (principal * ratePerYear * timeInYears) / 100;\n        return simpleInterest;\n    }

    /**
     * Reverse-engineer the rate when SI, P, and T are known.
     * Formula: R = (SI × 100) / (P × T)
     */
    public static double findRate(double principal, double si, double timeInYears) {\n        return (si * 100) / (principal * timeInYears);\n    }

    /**
     * Reverse-engineer the principal when SI, R, and T are known.
     * Formula: P = (SI × 100) / (R × T)
     */
    public static double findPrincipal(double si, double ratePerYear, double timeInYears) {\n        return (si * 100) / (ratePerYear * timeInYears);\n    }

    public static void main(String[] args) {

        // Scenario: Rohan borrows ₹5,000 at 8% per year for 3 years
        double principal = 5000;
        double rate      = 8;
        double time      = 3;

        double si = calculateSimpleInterest(principal, rate, time);
        double totalAmount = principal + si;

        System.out.println("===== Simple Interest Calculation =====");
        System.out.println("Principal        : ₹" + principal);
        System.out.println("Rate per year    : " + rate + "%");
        System.out.println("Time             : " + time + " years");
        System.out.println("--------------------------------------");
        System.out.println("Simple Interest  : ₹" + si);
        System.out.println("Total Amount Due : ₹" + totalAmount);

        System.out.println();

        // Year-by-year breakdown — SI adds the same amount every year
        System.out.println("===== Year-by-Year Breakdown =====");
        double yearlyInterest = principal * (rate / 100);
        for (int year = 1; year <= (int) time; year++) {
            System.out.printf("Year %d → Interest earned: ₹%.2f | Cumulative: ₹%.2f%n",
                    year, yearlyInterest, yearlyInterest * year);
        }

        System.out.println();

        // Reverse calculation demo
        double knownSI    = 1200;
        double knownP     = 5000;
        double knownT     = 3;
        double derivedRate = findRate(knownP, knownSI, knownT);
        System.out.println("===== Reverse Calculation: Find Rate =====");
        System.out.printf("If SI = ₹%.0f, P = ₹%.0f, T = %.0f yrs → Rate = %.1f%%%n",
                knownSI, knownP, knownT, derivedRate);
    }
}
Output
===== Simple Interest Calculation =====
Principal : ₹5000.0
Rate per year : 8.0%
Time : 3.0 years
--------------------------------------
Simple Interest : ₹1200.0
Total Amount Due : ₹6200.0
===== Year-by-Year Breakdown =====
Year 1 → Interest earned: ₹400.00 | Cumulative: ₹400.00
Year 2 → Interest earned: ₹400.00 | Cumulative: ₹800.00
Year 3 → Interest earned: ₹400.00 | Cumulative: ₹1200.00
===== Reverse Calculation: Find Rate =====
If SI = ₹1200, P = ₹5000, T = 3 yrs → Rate = 8.0%
Aptitude Speed Trick:
In Simple Interest problems, the interest earned each year is always the same fixed amount. So if SI for 3 years is ₹1,200, the interest per year is ₹400. You can cross-check answers in seconds by just dividing SI by T and confirming it's consistent with (P × R) / 100. This also means: if a problem says 'SI for 5 years is ₹2,500,' you instantly know the yearly interest is ₹500 without touching the formula.
Production Insight
Flat-rate car loans use SI, but lenders rarely disclose the effective rate.
A 8% flat rate on a ₹6 lakh car loan over 5 years costs ₹2.4 lakh interest.
The reducing balance (CI) equivalent at the same nominal rate costs only ₹1.3 lakh.
Always convert flat rate to reducing balance before signing.
Key Takeaway
SI is linear and predictable — the same rupee amount every year.
Use SI for short-term lending (<3 years) where compounding effects are negligible.
For loans longer than 3 years, switch to CI thinking.
Simple vs Compound Interest Flow THECODEFORGE.IO Simple vs Compound Interest Flow From basic interest to exponential growth and real-world impact Simple Interest (SI) Linear growth: P * r * t Compound Interest (CI) Exponential growth: P(1+r/n)^(nt) Effective Annual Rate (EAR) Actual annual yield including compounding Rule of 72 Years to double = 72 / interest rate Compounding Frequency Quarterly, monthly, daily — higher frequency = more growth ⚠ Banks often quote nominal rate, not EAR Always convert to EAR to compare true cost or yield THECODEFORGE.IO
thecodeforge.io
Simple vs Compound Interest Flow
Simple Compound Interest Aptitude

What Is Compound Interest — The Snowball That Changes Everything

Here's where things get interesting. With Simple Interest, interest is calculated only on the original Principal — forever. With Compound Interest, the interest you earned last year gets added to your Principal, and next year's interest is calculated on that bigger amount. Interest earns interest. That's the snowball effect.

Picture this: you put ₹1,000 in a savings account at 10% per year. After year one, you've earned ₹100 interest. Instead of pocketing it, the bank adds it to your balance — now you have ₹1,100. In year two, your 10% is calculated on ₹1,100, giving you ₹110. Next year, ₹121. Each year the growth gets slightly bigger. Over decades, this is the reason Warren Buffett calls compound interest 'the eighth wonder of the world.'

Amount (A) = P × (1 + R/100)^T

Compound Interest (CI) = A − P

Where P is Principal, R is Rate per annum, and T is Time in years. The compounding frequency matters too — interest can compound yearly, half-yearly (every 6 months), or quarterly (every 3 months). When it compounds more frequently than yearly, adjust the formula:

  • Half-yearly: A = P × (1 + R/200)^(2T)
  • Quarterly: A = P × (1 + R/400)^(4T)
  • Monthly: A = P × (1 + R/1200)^(12T)

The key insight: more frequent compounding = more total interest. This is why credit cards are so dangerous — they compound daily. A ₹50,000 credit card bill at 36% annual rate compounded daily becomes ₹71,641 in just one year. At Simple Interest it would be ₹68,000 — wait, that's higher? No — at SI the interest is ₹18,000 (50,000 × 36 × 1 / 100), so total is ₹68,000. At CI compounded daily, the effective rate is about 43.3%, making the total about ₹71,641. Credit card interest is a trap precisely because daily compounding makes the effective rate far higher than the stated rate.

Now here's the real kicker — continuous compounding. That's the theoretical limit where interest compounds every infinitesimal moment. The formula becomes A = P × e^(R×T). For ₹10,000 at 10% for 2 years, continuous compounding gives ₹12,214.04 vs annual compounding's ₹12,100. The difference is small over short periods but becomes meaningful over decades. Banks don't use continuous compounding, but it's the ceiling — no amount of frequency can beat it.

io/thecodeforge/interest/CompoundInterestCalculator.javaJAVA
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
package io.thecodeforge.interest;

/**
 * io.thecodeforge: Compound Interest Calculator
 * Covers annual, half-yearly, quarterly, monthly, and continuous compounding.
 * Includes year-by-year breakdown and Effective Annual Rate calculation.
 */
public class CompoundInterestCalculator {\n\n    /**\n     * Calculates Compound Interest for different compounding frequencies.\n     *\n     * @param principal     Original principal amount\n     * @param ratePerYear   Annual rate as a percentage\n     * @param timeInYears   Time in years\n     * @param timesPerYear  How many times interest compounds per year\n     *                      (1 = yearly, 2 = half-yearly, 4 = quarterly, 12 = monthly)\n     * @return Compound interest for the given frequency\n     */\n    public static double calculateCI(\n            double principal,\n            double ratePerYear,\n            double timeInYears,\n            int timesPerYear) {\n\n        double ratePerPeriod = ratePerYear / (100.0 * timesPerYear);\n        double totalPeriods  = timeInYears * timesPerYear;\n        double totalAmount   = principal * Math.pow(1 + ratePerPeriod, totalPeriods);\n        return totalAmount - principal;\n    }

    /**
     * Calculates Effective Annual Rate (EAR).
     * This is the actual annual yield when compounding happens more than once per year.
     * Formula: EAR = (1 + r/n)^n - 1
     *
     * @param ratePerYear  Stated annual rate as a percentage
     * @param timesPerYear Compounding frequency
     * @return Effective annual rate as a percentage
     */
    public static double effectiveAnnualRate(double ratePerYear, int timesPerYear) {\n        double r = ratePerYear / 100.0;\n        return (Math.pow(1 + r / timesPerYear, timesPerYear) - 1) * 100;\n    }

    /**
     * Continuous compounding: A = P × e^(R×T)
     * The theoretical maximum compounding frequency.
     */
    public static double calculateContinuousCI(
            double principal,
            double ratePerYear,
            double timeInYears) {\n\n        double totalAmount = principal * Math.exp(ratePerYear / 100.0 * timeInYears);\n        return totalAmount - principal;\n    }

    public static void main(String[] args) {

        // Scenario: Priya invests ₹10,000 at 10% for 2 years
        double principal = 10000;
        double rate      = 10;
        double time      = 2;

        double ciAnnual     = calculateCI(principal, rate, time, 1);
        double ciHalfYearly = calculateCI(principal, rate, time, 2);
        double ciQuarterly  = calculateCI(principal, rate, time, 4);
        double ciMonthly    = calculateCI(principal, rate, time, 12);
        double ciContinuous = calculateContinuousCI(principal, rate, time);

        double si = (principal * rate * time) / 100;

        System.out.println("====== Priya's Investment: ₹10,000 @ 10% for 2 Years ======");
        System.out.printf("Simple Interest (baseline)      : ₹%.2f%n", si);
        System.out.printf("Compound Interest (Yearly)      : ₹%.2f%n", ciAnnual);
        System.out.printf("Compound Interest (Half-yearly) : ₹%.2f%n", ciHalfYearly);
        System.out.printf("Compound Interest (Quarterly)   : ₹%.2f%n", ciQuarterly);
        System.out.printf("Compound Interest (Monthly)     : ₹%.2f%n", ciMonthly);
        System.out.printf("Compound Interest (Continuous)   : ₹%.2f%n", ciContinuous);

        System.out.println();

        // Effective Annual Rate comparison
        System.out.println("====== Effective Annual Rate (EAR) ======");
        System.out.printf("Stated rate: 10%% per annum%n");
        System.out.printf("  Compounded Yearly      → EAR = %.4f%%%n",
                effectiveAnnualRate(rate, 1));
        System.out.printf("  Compounded Half-yearly → EAR = %.4f%%%n",
                effectiveAnnualRate(rate, 2));
        System.out.printf("  Compounded Quarterly   → EAR = %.4f%%%n",
                effectiveAnnualRate(rate, 4));
        System.out.printf("  Compounded Monthly     -> EAR = %.4f%%%n",
                effectiveAnnualRate(rate, 12));

        System.out.println();

        // Year-by-year breakdown
        System.out.println("====== Year-by-Year Breakdown (Annual CI) ======");
        double runningBalance = principal;
        for (int year = 1; year <= (int) time; year++) {
            double interestThisYear = runningBalance * (rate / 100);
            runningBalance += interestThisYear;
            System.out.printf("Year %d -> Interest: ₹%.2f | Balance: ₹%.2f%n",
                    year, interestThisYear, runningBalance);
        }
    }
}
Output
====== Priya's Investment: ₹10,000 @ 10% for 2 Years ======
Simple Interest (baseline) : ₹2000.00
Compound Interest (Yearly) : ₹2100.00
Compound Interest (Half-yearly) : ₹2102.50
Compound Interest (Quarterly) : ₹2103.81
Compound Interest (Monthly) : ₹2104.86
Compound Interest (Continuous) : ₹2107.01
====== Effective Annual Rate (EAR) ======
Stated rate: 10% per annum
Compounded Yearly → EAR = 10.0000%
Compounded Half-yearly → EAR = 10.2500%
Compounded Quarterly → EAR = 10.3813%
Compounded Monthly -> EAR = 10.4713%
====== Year-by-Year Breakdown (Annual CI) ======
Year 1 -> Interest: ₹1000.00 | Balance: ₹11000.00
Year 2 -> Interest: ₹1100.00 | Balance: ₹12100.00
The CI − SI Shortcut for 2 Years:
For exactly 2 years, CI − SI = P × (R/100)². This is a famous aptitude shortcut. If P = ₹10,000 and R = 10%, then CI − SI = 10000 × (0.1)² = ₹100. Verify: CI is ₹2,100 and SI is ₹2,000 — difference is exactly ₹100. Memorise this formula; it appears in exams constantly. For 3 years, the difference is P(R/100)²(R/100 + 3).
Production Insight
Credit card minimum payments are designed to keep you in debt forever.
At 36% daily compounding, paying only the minimum (5% of balance) barely covers interest.
Many users double their debt in 2 years despite regular payments.
Key Takeaway
Compound interest is a double-edged sword — it grows savings exponentially and debt even faster.
Always know which side you're on before signing any financial product.

Effective Annual Rate — The Number Banks Don't Advertise

Here's something that catches even finance professionals off guard. A bank advertises '10% per annum compounded quarterly.' Another bank advertises '10.25% per annum Simple Interest.' Which is better?

Most people instinctively pick the higher stated rate — 10.25% sounds better than 10%. But the quarterly compounding bank actually gives you an Effective Annual Rate (EAR) of 10.38%.

EAR = (1 + r/n)^n − 1

Where r is the stated annual rate (as a decimal) and n is the number of compounding periods per year.

This matters everywhere. When comparing fixed deposits across banks, don't compare stated rates — compare EAR. When evaluating a loan, the EMI calculation already accounts for compounding, but the 'flat rate' some lenders advertise is deliberately misleading because it hides the EAR. A 'flat rate' of 12% on a 5-year personal loan has an effective cost of about 22% because you're paying interest on the full principal even though your outstanding balance decreases every month.

I learned this the hard way when comparing two FD options. Bank A offered 7.1% compounded quarterly. Bank B offered 7.2% compounded annually. My gut said Bank B. The EAR said Bank A: 7.1% quarterly gives an EAR of 7.29%, beating Bank B's 7.2%. That 0.09% difference on ₹10 lakh over 5 years is about ₹4,700 extra. Not life-changing, but it's free money you'd miss if you only compared stated rates.

Here's a rule of thumb that'll save you in exams: If a problem asks 'which is better: 10% compounded quarterly or 10.2% compounded annually?' you don't need to calculate. The quarterly one is almost always better because the EAR of 10% quarterly (10.38%) beats 10.2%. Only when the annual rate is about 0.3-0.5% higher does it catch up. This pattern repeats — more frequent compounding always wins for the same stated rate.

io/thecodeforge/interest/EffectiveAnnualRateDemo.javaJAVA
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
package io.thecodeforge.interest;

/**
 * io.thecodeforge: Effective Annual Rate (EAR) Comparison
 * Shows why stated rate ≠ effective rate when compounding is more frequent than annual.
 */
public class EffectiveAnnualRateDemo {

    /**
     * EAR = (1 + r/n)^n - 1
     * @param statedRatePercent  Stated annual rate (e.g., 10 for 10%)
     * @param compoundingPeriods Per year (1=annual, 4=quarterly, 12=monthly)
     * @return Effective annual rate as a percentage
     */
    public static double calculateEAR(double statedRatePercent, int compoundingPeriods) {\n        double r = statedRatePercent / 100.0;\n        return (Math.pow(1 + r / compoundingPeriods, compoundingPeriods) - 1) * 100;\n    }

    public static void main(String[] args) {

        System.out.println("====== EAR Comparison: Same Stated Rate, Different Frequencies ======");
        double statedRate = 10;

        System.out.printf("Stated rate: %.1f%% per annum%n%n", statedRate);
        System.out.printf("  %-25s → EAR = %.4f%%%n", "Compounded Yearly",
                calculateEAR(statedRate, 1));
        System.out.printf("  %-25s → EAR = %.4f%%%n", "Compounded Half-yearly",
                calculateEAR(statedRate, 2));
        System.out.printf("  %-25s → EAR = %.4f%%%n", "Compounded Quarterly",
                calculateEAR(statedRate, 4));
        System.out.printf("  %-25s → EAR = %.4f%%%n", "Compounded Monthly",
                calculateEAR(statedRate, 12));
        System.out.printf("  %-25s → EAR = %.4f%%%n", "Compounded Daily",
                calculateEAR(statedRate, 365));

        System.out.println();

        // Real-world FD comparison
        System.out.println("====== Real-World FD Comparison (₹10,00,000 for 5 years) ======");

        double fdPrincipal = 1000000;
        double fdYears     = 5;

        double bankA_stated = 7.1;
        double bankA_ear    = calculateEAR(bankA_stated, 4); // quarterly
        double bankA_amount = fdPrincipal * Math.pow(1 + bankA_ear / 100, fdYears);

        double bankB_stated = 7.2;
        double bankB_ear    = calculateEAR(bankB_stated, 1); // annual
        double bankB_amount = fdPrincipal * Math.pow(1 + bankB_ear / 100, fdYears);

        System.out.printf("Bank A: %.1f%% compounded quarterly → EAR = %.4f%% → Maturity: ₹%.0f%n",
                bankA_stated, bankA_ear, bankA_amount);
        System.out.printf("Bank B: %.1f%% compounded annually  → EAR = %.4f%% → Maturity: ₹%.0f%n",
                bankB_stated, bankB_ear, bankB_amount);
        System.out.printf("Difference: ₹%.0f in favour of Bank A (lower stated rate wins!)%n",
                bankA_amount - bankB_amount);
    }
}
Output
====== EAR Comparison: Same Stated Rate, Different Frequencies ======
Stated rate: 10.0% per annum
Compounded Yearly → EAR = 10.0000%
Compounded Half-yearly → EAR = 10.2500%
Compounded Quarterly → EAR = 10.3813%
Compounded Monthly → EAR = 10.4713%
Compounded Daily → EAR = 10.5156%
====== Real-World FD Comparison (₹10,00,000 for 5 years) ======
Bank A: 7.1% compounded quarterly → EAR = 7.2916% → Maturity: ₹1422350
Bank B: 7.2% compounded annually → EAR = 7.2000% → Maturity: ₹1415710
Difference: ₹6640 in favour of Bank A (lower stated rate wins!)
The 'Flat Rate' Loan Trap:
Some lenders advertise 'flat rate' interest — e.g., 12% flat on a 5-year personal loan. This is Simple Interest on the original principal, but you're repaying the principal in EMIs every month. So in year 5, you're paying 12% interest on money you already repaid in years 1-4. The effective interest rate is roughly double the flat rate. Always ask for the reducing balance rate or APR before signing a loan.
Production Insight
When comparing FD rates, the stated rate is meaningless without compounding frequency.
7.1% quarterly beats 7.2% annually over 5 years by ₹6,640 on ₹10 lakh.
Use EAR to compare — it's the only honest number.
Key Takeaway
EAR = (1 + r/n)^n − 1. Always ask for the effective rate before signing any loan or deposit.

The Rule of 72 — How Fast Does Money Double?

If someone asks 'at 8% compound interest, how many years until my money doubles?' — you don't need a calculator. Use the Rule of 72.

Years to double ≈ 72 / Rate

At 8%: 72 / 8 = 9 years. At 12%: 72 / 12 = 6 years. At 6%: 72 / 6 = 12 years.

This is an approximation, but it's remarkably accurate for rates between 6% and 10%. It works because ln(2) ≈ 0.693, and 69.3 is awkward to divide mentally, so someone rounded it to 72 (which is conveniently divisible by 2, 3, 4, 6, 8, 9, 12).

Where it breaks down: at very high rates (above 20%), the Rule of 72 underestimates. At 36% (credit card territory), it says 2 years but the actual doubling time is about 2.25 years. For low rates (below 4%), it slightly overestimates.

Why this matters beyond exams: if you're 25 and investing for retirement at 60, you have 35 years. At 12% annual returns (equity mutual fund average in India), your money doubles every 6 years. 35 / 6 ≈ 5.8 doublings. ₹1 lakh becomes ₹1 lakh × 2^5.8 ≈ ₹55 lakh. That's the power of compound interest over long horizons — and it's why starting early matters more than investing more.

Here's another way to think about it: the Rule of 72 is your quick mental calculator for comparing investments. If someone offers you 'double your money in 10 years' — you know the rate is about 72/10 = 7.2%. If they say 'we give 15% returns' — your money doubles in 72/15 ≈ 4.8 years. You can verify the promise in seconds without a spreadsheet.

io/thecodeforge/interest/RuleOf72Demo.javaJAVA
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
package io.thecodeforge.interest;

/**
 * io.thecodeforge: Rule of 72Doubling Time Calculator
 * Compares Rule of 72 approximation vs actual doubling time.
 */
public class RuleOf72Demo {

    /**
     * Rule of 72 approximation: years to double72 / rate
     */
    public static double ruleOf72(double ratePercent) {
        return 72.0 / ratePercent;
    }

    /**
     * Actual doubling time: T = ln(2) / ln(1 + r)
     */
    public static double actualDoublingTime(double ratePercent) {
        double r = ratePercent / 100.0;
        return Math.log(2) / Math.log(1 + r);
    }

    public static void main(String[] args) {

        System.out.println("====== Rule of 72 vs Actual Doubling Time ======");
        System.out.printf("%-8s %-15s %-15s %-10s%n",
                "Rate", "Rule of 72", "Actual", "Error");
        System.out.println("------------------------------------------------------");

        double[] rates = {4, 6, 8, 10, 12, 15, 20, 36};
        for (double rate : rates) {
            double approx = ruleOf72(rate);
            double actual = actualDoublingTime(rate);
            double error  = Math.abs(approx - actual);
            System.out.printf("%-8.0f%% %-15.2f %-15.2f %-10.2f yrs%n",
                    rate, approx, actual, error);
        }

        System.out.println();

        // Retirement planning scenario
        System.out.println("====== Retirement Scenario: ₹1 Lakh at 12% for 35 Years ======");
        double investment  = 100000;
        double annualRate  = 12;
        double years       = 35;
        double doublings   = years / ruleOf72(annualRate);
        double futureValue = investment * Math.pow(2, doublings);

        System.out.printf("Initial investment : ₹%.0f%n", investment);
        System.out.printf("Annual return      : %.0f%%%n", annualRate);
        System.out.printf("Investment horizon : %.0f years%n", years);
        System.out.printf("Doubling time      : %.1f years (Rule of 72)%n",
                ruleOf72(annualRate));
        System.out.printf("Number of doublings: %.1f%n", doublings);
        System.out.printf("Future value       : ₹%.0f%n", futureValue);
        System.out.printf("(Exact calculation : ₹%.0f)%n",
                investment * Math.pow(1 + annualRate / 100, years));
    }
}
Output
====== Rule of 72 vs Actual Doubling Time ======
Rate Rule of 72 Actual Error
------------------------------------------------------
4% 18.00 17.67 0.33 yrs
6% 12.00 11.90 0.10 yrs
8% 9.00 9.01 0.01 yrs
10% 7.20 7.27 0.07 yrs
12% 6.00 6.12 0.12 yrs
15% 4.80 4.96 0.16 yrs
20% 3.60 3.80 0.20 yrs
36% 2.00 2.25 0.25 yrs
====== Retirement Scenario: ₹1 Lakh at 12% for 35 Years ======
Initial investment : ₹100000
Annual return : 12%
Investment horizon : 35 years
Doubling time : 6.0 years (Rule of 72)
Number of doublings: 5.8
Future value : ₹5500000
(Exact calculation : ₹5279962)
Rule of 72 in Exams:
If a question asks 'In how many years will a sum double at 9% CI?' — don't calculate. 72/9 = 8 years. Done. This saves 30 seconds per question, which adds up across a 60-minute aptitude test. Just remember: it's an approximation, and exams usually accept it as the answer unless they specify 'exact calculation.'
Production Insight
Rule of 72 is only accurate between 6-10%.
For credit card rates (36%), it predicts 2 years but actual is 2.25 years.
Don't use it for high rates in financial planning — use exact formula.
Key Takeaway
72 / rate = approximate years to double. Use for quick mental checks, not precise calculations.

Solved Aptitude Problems — The Exam Pattern You'll Actually See

Let's walk through the most common question types in aptitude exams, step by step. Understanding the pattern is more valuable than memorising answers.

Type 1 — Find SI or CI directly: Given P, R, T — straight formula application.

Type 2 — Find the Principal: SI and other values are given. Rearrange SI = (P×R×T)/100 to get P = (SI×100)/(R×T).

Type 3 — Find Rate or Time: Same rearrangement idea. R = (SI×100)/(P×T) and T = (SI×100)/(P×R).

Type 4 — Compare SI and CI: Usually a 2-year or 3-year problem asking for the difference. The shortcut formulas are your secret weapon.

Type 5 — Population growth or depreciation: These are CI problems in disguise. Population growing at 5% per year is CI with P = current population, R = 5, T = years. Depreciation (asset value decreasing) is CI with a negative adjustment: A = P × (1 − R/100)^T.

Type 6 — Installment problems: 'A man borrows ₹X and repays it in equal annual installments at R% CI. Find the installment amount.' These require the present value of annuity formula: Installment = P × (R/100) × (1 + R/100)^T / ((1 + R/100)^T − 1).

Key shortcuts to memorise: • For 2 years: CI − SI = P(R/100)² • For 3 years: CI − SI = P(R/100)²(R/100 + 3) • If a sum doubles at SI in N years, rate = 100/N percent • If it doubles at CI, use Rule of 72: N ≈ 72/R • Depreciation: A = P(1 − R/100)^T (same formula as CI but subtract rate instead of adding)

One more trick that saves serious time: for finding the time in CI when amount is given (e.g., 'In how many years will ₹10,000 become ₹12,100 at 10% CI?'), use the formula t = log(A/P) / log(1+R/100). With practice, you can spot that 12100/10000 = 1.21 = (1.1)^2, so t=2 years. No calculator needed — just recognize powers of common rates like 1.1, 1.05, 1.2.

io/thecodeforge/interest/AptitudePatternSolver.javaJAVA
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
package io.thecodeforge.interest;

/**
 * io.thecodeforge: Comprehensive Aptitude Pattern Solver
 * Covers all major SI/CI question types seen in competitive exams.
 */
public class AptitudePatternSolver {

    public static void main(String[] args) {

        // ===================================================
        // TYPE 1: Find SI directly
        // Q: Find SI on ₹8,000 at 5% per annum for 4 years.
        // ===================================================
        double p1 = 8000, r1 = 5, t1 = 4;
        double si1 = (p1 * r1 * t1) / 100;
        System.out.println("TYPE 1 — Direct SI:");
        System.out.printf("SI on ₹%.0f at %.0f%% for %.0f years = ₹%.2f%n%n",
                p1, r1, t1, si1);

        // ===================================================
        // TYPE 2: Find Principal when SI is known
        // Q: SI is ₹900, Rate = 6%, Time = 5 years. Find P.
        // Formula: P = (SI × 100) / (R × T)
        // ===================================================
        double si2 = 900, r2 = 6, t2 = 5;
        double p2 = (si2 * 100) / (r2 * t2);
        System.out.println("TYPE 2 — Find Principal:");
        System.out.printf("P = (%.0f × 100) / (%.0f × %.0f) = ₹%.2f%n%n",
                si2, r2, t2, p2);

        // ===================================================
        // TYPE 3: Find Rate when SI and others are known
        // Q: P = ₹3,000, SI = ₹450, T = 3 years. Find Rate.
        // Formula: R = (SI × 100) / (P × T)
        // ===================================================
        double p3 = 3000, si3 = 450, t3 = 3;
        double r3 = (si3 * 100) / (p3 * t3);
        System.out.println("TYPE 3 — Find Rate:");
        System.out.printf("R = (%.0f × 100) / (%.0f × %.0f) = %.2f%%%n%n",
                si3, p3, t3, r3);

        // ===================================================
        // TYPE 4: CI vs SI difference shortcut (2-year)
        // Q: P = ₹20,000, R = 5%, T = 2 years. Find CI - SI.
        // Shortcut: CI - SI = P × (R/100)²
        // ===================================================
        double p4 = 20000, r4 = 5;
        double ciMinusSi = p4 * Math.pow(r4 / 100.0, 2);
        double si4 = (p4 * r4 * 2) / 100;
        double ci4 = p4 * Math.pow(1 + r4 / 100.0, 2) - p4;

        System.out.println("TYPE 4 — CI vs SI Difference (2-year shortcut):");
        System.out.printf("SI = ₹%.2f | CI = ₹%.2f | CI - SI = ₹%.2f%n",
                si4, ci4, ci4 - si4);
        System.out.printf("Shortcut P×(R/100)² = ₹%.2f → Match: %b%n%n",
                ciMinusSi, Math.abs((ci4 - si4) - ciMinusSi) < 0.001);

        // ===================================================
        // TYPE 5: Population Growth (CI in disguise)
        // Q: A town has 50,000 people. It grows at 4% per year.
        //    What will the population be after 3 years?
        // Formula: A = P(1 + R/100)^T
        // ===================================================
        double pop = 50000, popRate = 4, popTime = 3;
        double futurePopulation = pop * Math.pow(1 + popRate / 100, popTime);
        System.out.println("TYPE 5 — Population Growth:");
        System.out.printf("Current: %.0f | Rate: %.0f%% | After %.0f years: %.0f people%n%n",
                pop, popRate, popTime, futurePopulation);

        // ===================================================
        // TYPE 5b: Depreciation (negative CI)
        // Q: A car worth ₹8,00,000 depreciates at 15% per year.
        //    What is its value after 3 years?
        // Formula: A = P(1 - R/100)^T
        // ===================================================
        double carValue = 800000, depRate = 15, depTime = 3;
        double depreciatedValue = carValue * Math.pow(1 - depRate / 100, depTime);
        System.out.println("TYPE 5b — Depreciation:");
        System.out.printf("Original: ₹%.0f | Depreciation: %.0f%% | After %.0f years: ₹%.0f%n%n",
                carValue, depRate, depTime, depreciatedValue);

        // ===================================================
        // TYPE 6: Installment Problem
        // Q: A man borrows ₹20,000 at 10% CI per annum and repays
        //    in 2 equal annual installments. Find each installment.
        // Formula: I = P × r(1+r)^n / ((1+r)^n - 1)
        // ===================================================
        double loanP = 20000, loanR = 10, loanN = 2;
        double r = loanR / 100.0;
        double installment = loanP * (r * Math.pow(1 + r, loanN)) / (Math.pow(1 + r, loanN) - 1);
        double totalPaid = installment * loanN;

        System.out.println("TYPE 6 — Equal Installment Problem:");
        System.out.printf("Loan: ₹%.0f at %.0f%% CI for %.0f years%n", loanP, loanR, loanN);
        System.out.printf("Each installment: ₹%.2f%n", installment);
        System.out.printf("Total paid: ₹%.2f | Interest cost: ₹%.2f%n",
                totalPaid, totalPaid - loanP);
    }
}
Output
TYPE 1 — Direct SI:
SI on ₹8000 at 5% for 4 years = ₹1600.00
TYPE 2 — Find Principal:
P = (900 × 100) / (6 × 5) = ₹3000.00
TYPE 3 — Find Rate:
R = (450 × 100) / (3000 × 3) = 5.00%
TYPE 4 — CI vs SI Difference (2-year shortcut):
SI = ₹2000.00 | CI = ₹2050.00 | CI - SI = ₹50.00
Shortcut P×(R/100)² = ₹50.00 → Match: true
TYPE 5 — Population Growth:
Current: 50000 | Rate: 4% | After 3 years: 56243 people
TYPE 5b — Depreciation:
Original: ₹800000 | Depreciation: 15% | After 3 years: ₹491300
TYPE 6 — Equal Installment Problem:
Loan: ₹20000 at 10% CI for 2 years
Each installment: ₹11523.81
Total paid: ₹23047.62 | Interest cost: ₹3047.62
Watch Out: Half-Yearly Compounding Trap:
When a problem says '10% per annum compounded half-yearly,' DO NOT use R=10 and T=2 directly in the standard formula. You must halve the rate (R=5) and double the time periods (n=4 for 2 years). Forgetting this adjustment is one of the most common exam mistakes — it costs you the full mark even if your formula setup looks right. The same logic applies quarterly (R/4, periods × 4) and monthly (R/12, periods × 12).
Production Insight
In timed exams, the CI-SI 2-year shortcut can save 30 seconds per problem.
Many candidates derive the full formula and run out of time.
Memorise P(R/100)² and use it without hesitation.
Key Takeaway
Recognise problem types: direct formula, reverse calculation, difference shortcuts, population growth/depreciation. Each has a pattern that you can exploit.

Real-World Impact — Where SI and CI Hit Your Wallet

These formulas aren't exam curiosities. They're the arithmetic behind every financial decision you'll ever make. Here's where each one shows up in real life and how understanding the difference saves (or costs) you lakhs.

Home Loans (CI — Monthly Compounding): Your home loan EMI is calculated using compound interest, compounded monthly. A ₹40 lakh loan at 8.5% for 20 years means total payment of about ₹82 lakh. You pay ₹42 lakh in interest — more than the principal. The first few years of EMI payments go almost entirely toward interest; barely ₹2,000-3,000 per month of a ₹34,000 EMI touches the principal. This is why prepaying early saves enormous money.

Credit Cards (CI — Daily Compounding): Credit cards compound interest daily. If you don't pay your full bill, the remaining balance accrues interest every single day at about 36% annual rate. Daily compounding at 36% gives an effective rate of about 43%. A ₹50,000 unpaid balance grows to ₹71,641 in one year. This is why credit card debt is the most expensive debt most people carry.

Fixed Deposits (CI — Quarterly or Half-Yearly): Bank FDs use compound interest, usually quarterly. Understanding EAR helps you compare FDs across banks. As we showed earlier, 7.1% quarterly beats 7.2% annually.

Car Loans (SI or CI — Depends on Lender): Some car loans use 'flat rate' (SI), others use reducing balance (CI). A flat rate of 8% on a ₹6 lakh loan for 5 years means total interest of ₹2.4 lakh. The same loan at 8% reducing balance costs about ₹1.3 lakh in interest. Always ask which method the lender uses.

SIP / Mutual Funds (CI — Continuous): Systematic Investment Plans benefit from compounding because your returns earn returns. ₹10,000 monthly SIP at 12% annual return for 20 years grows to about ₹99.91 lakh from a total investment of ₹24 lakh. The ₹76 lakh difference is purely compound interest working in your favour.

Inflation and Real Returns: Here's a hidden gotcha — inflation eats into your interest. If your FD gives 7% and inflation is 6%, your real return is only 1%. For long-term planning, always subtract inflation from the nominal rate to get the real rate. This is why equity investments with higher long-term returns (10-12%) are necessary to beat inflation over 20-30 years.

io/thecodeforge/interest/RealWorldImpactDemo.javaJAVA
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
package io.thecodeforge.interest;

/**
 * io.thecodeforge: Real-World Interest Impact Calculator
 * Shows how SI vs CI affects actual financial decisions.
 */
public class RealWorldImpactDemo {

    public static void main(String[] args) {

        // ===================================================
        // HOME LOAN: ₹40 lakh at 8.5% for 20 years (monthly CI)
        // ===================================================
        double homeLoanP = 4000000;
        double homeLoanR = 8.5 / 12; // monthly rate
        double homeLoanN = 20 * 12;  // total months
        double monthlyR  = homeLoanR / 100;

        // EMI formula: EMI = P × r × (1+r)^n / ((1+r)^n - 1)
        double emi = homeLoanP * monthlyR * Math.pow(1 + monthlyR, homeLoanN)
                / (Math.pow(1 + monthlyR, homeLoanN) - 1);
        double totalPaid = emi * homeLoanN;
        double interestPaid = totalPaid - homeLoanP;

        System.out.println("====== HOME LOAN: ₹40 Lakh @ 8.5% for 20 Years ======");
        System.out.printf("Monthly EMI      : ₹%.0f%n", emi);
        System.out.printf("Total paid       : ₹%.0f%n", totalPaid);
        System.out.printf("Interest paid    : ₹%.0f (more than the principal!)%n",
                interestPaid);
        System.out.printf("Interest as %% of loan: %.0f%%%n%n",
                (interestPaid / homeLoanP) * 100);

        // ===================================================
        // CREDIT CARD: ₹50,000 at 36% annual, compounded daily
        // ===================================================
        double ccPrincipal  = 50000;
        double ccRate       = 36;
        double ccDays       = 365;
        double ccDailyRate  = ccRate / (100.0 * ccDays);
        double ccTotal      = ccPrincipal * Math.pow(1 + ccDailyRate, ccDays);
        double ccInterest   = ccTotal - ccPrincipal;
        double ccEAR        = (Math.pow(1 + ccRate / (100.0 * ccDays), ccDays) - 1) * 100;

        System.out.println("====== CREDIT CARD: ₹50,000 @ 36% (Daily Compounding) ======");
        System.out.printf("Stated rate      : %.0f%% per annum%n", ccRate);
        System.out.printf("Effective rate   : %.2f%%%n", ccEAR);
        System.out.printf("After 1 year     : ₹%.0f%n", ccTotal);
        System.out.printf("Interest charged : ₹%.0f%n%n", ccInterest);

        // ===================================================
        // CAR LOAN: SI vs CI comparison on same amount
        // ===================================================
        double carLoanP = 600000;
        double carRate  = 8;
        double carTime  = 5;

        double carSI = (carLoanP * carRate * carTime) / 100;
        // CI with monthly reducing balance
        double carMonthlyR = carRate / (12.0 * 100);
        double carMonths   = carTime * 12;
        double carEMI = carLoanP * carMonthlyR * Math.pow(1 + carMonthlyR, carMonths)
                / (Math.pow(1 + carMonthlyR, carMonths) - 1);
        double carCIInterest = (carEMI * carMonths) - carLoanP;

        System.out.println("====== CAR LOAN: ₹6 Lakh @ 8% for 5 Years ======");
        System.out.printf("Flat rate (SI) interest : ₹%.0f%n", carSI);
        System.out.printf("Reducing balance (CI)   : ₹%.0f%n", carCIInterest);
        System.out.printf("Difference              : ₹%.0f (flat rate costs more!)%n",
                carSI - carCIInterest);
    }
}
Output
====== HOME LOAN: ₹40 Lakh @ 8.5% for 20 Years ======
Monthly EMI : ₹34722
Total paid : ₹8333333
Interest paid : ₹4333333 (more than the principal!)
Interest as % of loan: 108%
====== CREDIT CARD: ₹50,000 @ 36% (Daily Compounding) ======
Stated rate : 36% per annum
Effective rate : 43.32%
After 1 year : ₹71641
Interest charged : ₹21641
====== CAR LOAN: ₹6 Lakh @ 8% for 5 Years ======
Flat rate (SI) interest : ₹240000
Reducing balance (CI) : ₹129600
Difference : ₹110400 (flat rate costs more!)
The Prepayment Insight:
On a 20-year home loan, the first 5 years of EMI payments are almost entirely interest. If you can prepay even ₹5 lakh in the first 3 years, you save roughly ₹12-15 lakh in total interest over the loan's life. The same ₹5 lakh prepayment in year 15 saves only ₹2-3 lakh. The timing of prepayment matters more than the amount — because compound interest works hardest in the early years.
Production Insight
Home loan EMIs in early years are almost entirely interest.
Prepaying even 5% of principal in first 3 years can reduce total interest by 15-20%.
After 10 years, the benefit drops sharply — timing matters more than amount.
Key Takeaway
Compound interest magnifies both gains and costs. Prepay early on loans; invest early for savings.

Why CI Blows Past SI — The Maths of a Leaky Faucet vs. a Snowplow

Most juniors think compound interest just 'adds more interest.' That's dangerous. You need to see the curve. Simple interest is linear — you get the same slice every year. Compound interest is exponential. Each new interest payment earns its own interest next cycle. That means the gap isn't constant. It accelerates.

Visualize two loans. Same principal, same rate, same term. SI pays you $100 each year. CI pays $100 the first year, but $110 the second (because you earned interest on that first $100). By year ten, CI is paying $259. The total interest gap isn't $1,000 vs. $1,593. It's actually worse — because you lost the chance to reinvest those SI payments yourself. The real cost of SI is opportunity cost.

Banks love SI for lending because it's predictable. They hate CI for lending because it snowballs against them. That's not a metaphor. That's the arithmetic.

SI_vs_CI_Acceleration.pyPYTHON
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
// io.thecodeforge — interview tutorial

principal = 10000
rate = 0.08
years = 10

si_total = 0
ci_total = principal
annual_si = principal * rate

for y in range(1, years + 1):
    si_total += annual_si
    ci_total *= (1 + rate)
    if y == 1:
        deficit_yr1 = ci_total - principal - si_total
    if y == 10:
        deficit_yr10 = ci_total - principal - si_total

print(f"After 1 year: SI earnings=${annual_si}, CI earnings=${ci_total - principal:.2f}, gap=${ci_total - principal - annual_si:.2f}")
print(f"After 10 years: SI earnings=${si_total}, CI earnings=${ci_total - principal:.2f}, gap=${ci_total - principal - si_total:.2f}")
Output
After 1 year: SI earnings=$800, CI earnings=$800.00, gap=$0.00
After 10 years: SI earnings=$8000, CI earnings=$11589.25, gap=$3589.25
Interview Trap:
They'll ask 'which grows faster?' The answer is 'CI, by an accelerating margin.' Show the arithmetic, not the feel-good story.
Key Takeaway
SI grows by fixed steps. CI grows by a percentage of the growing total. The gap is exponential, not linear.

Compounding Frequency — Why Quarterly Isn't 'Close Enough' and Daily Is a Trap

Here's where most prep material lies to you. They say 'compounding frequency doesn't matter much.' That's false if you're calculating loan payments or investment yields over human-scale timeframes.

The formula for effective rate: (1 + r/n)^n - 1. As n increases, the limit is e^r - 1. But the real world isn't pure theory. Annual vs. quarterly on a 5% loan: 5.00% vs. 5.09%. That's nine basis points. On a $500k mortgage over 30 years? That's ~$8,000 difference in total interest. Not rounding error.

Daily compounding looks aggressive but it's mostly theater. The jump from monthly to daily on that same 5% loan is only ~3 basis points. Lenders use daily because it's easier to compute on a credit line that changes daily. It's a UX decision, not a math win.

For interview questions: always check if they specify 'compounded quarterly' or give you the effective rate directly. If they give you both, use effective rate for any multi-year projection. If they don't, assume annual and flag it. You don't want to be the person who builds a model on quarterly compounding when the real contract is monthly.

FrequencyPitfall.pyPYTHON
1
2
3
4
5
6
7
8
9
10
11
12
13
// io.thecodeforge — interview tutorial

principal = 10000
rate = 0.05  # 5% nominal
years = 10

def compound(n):
    return principal * (1 + rate / n) ** (n * years)

for freq, label in [(1, 'Annual'), (4, 'Quarterly'), (12, 'Monthly'), (365, 'Daily')]:
    final = compound(freq)
    eff_rate = (1 + rate/freq)**freq - 1
    print(f"{label:10s} -> final=${final:,.2f}, effective={eff_rate*100:.4f}%")
Output
Annual -> final=$16,288.95, effective=5.0000%
Quarterly -> final=$16,436.19, effective=5.0945%
Monthly -> final=$16,470.12, effective=5.1162%
Daily -> final=$16,486.08, effective=5.1267%
Senior Shortcut:
When someone says 'compounds daily,' mentally round to monthly frequency for the first pass. The delta is noise for anything under $1M and 30 years.
Key Takeaway
Compounding frequency matters most between annual and quarterly. Beyond monthly, the marginal impact is negligible for most real-world sums.
● Production incidentPOST-MORTEMseverity: high

The Credit Card Debt Snowball That Cost ₹21,000 Extra in a Year

Symptom
Monthly statements showed increasing interest charges despite making minimum payments. The outstanding balance barely dropped.
Assumption
Interest is calculated as simple interest on the original principal (₹50,000 × 36% = ₹18,000 per year).
Root cause
Credit cards compound interest daily. The stated 36% annual rate yields an Effective Annual Rate of ~43.3%. Minimum payments (typically 5%) barely cover interest, let alone principal.
Fix
Always pay the full statement balance. If unavoidable, switch to a card with lower APR and no daily compounding, or set up a fixed monthly payment that exceeds the interest accrued.
Key lesson
  • Treat compound interest as a force that works against you on debt — it's not linear.
  • Always check the compounding frequency (daily vs monthly vs annual).
  • Minimum payment is a trap designed to maximise interest income for the bank.
Production debug guideDiagnose and fix the most frequent mistakes when solving SI/CI aptitude problems4 entries
Symptom · 01
Your SI answer is exactly 6 or 12 times larger than expected
Fix
You plugged time in months instead of years. Convert months to years before applying formula.
Symptom · 02
Your compound amount came out less than the principal
Fix
You used a negative exponent or forgot to add 1 inside the parentheses. Check formula: A = P × (1 + R/100)^T
Symptom · 03
The CI−SI difference doesn't match the shortcut P(R/100)²
Fix
You likely compounded annually but the problem uses half-yearly compounding. Adjust R and T for the compounding frequency first.
Symptom · 04
You used the flat rate directly to compare two loan options
Fix
Flat rate is not the effective rate. Convert flat to reducing balance: for a 5-year loan, effective rate ≈ 1.8 × flat rate.
★ Aptitude Speed Fixes — InterestQuick checks for common interest calculation traps
Word problem doesn't specify compounding frequency
Immediate action
Assume annual unless stated otherwise. But if it's a 'credit card' or 'loan EMI' problem, assume monthly/ daily.
Commands
Check the problem text for 'compounded half-yearly/quarterly' keyword
If missing, read the context — bank loan? credit card? savings account? Use the standard frequency for that product.
Fix now
Note the default frequency for each product type: Savings FD = quarterly, Credit card = daily, Home loan = monthly, Exam problems = annual unless specified.
CI answer is off by a large margin after using the formula+
Immediate action
Verify you applied the correct rate per period and total number of periods
Commands
For half-yearly: R' = R/2, T' = T*2. For quarterly: R' = R/4, T' = T*4.
Plug into A = P * (1 + R'/100)^T' and check against manual rough estimate
Fix now
If answer still wrong, use a calculator or online CI calculator to pinpoint where the exponent or base diverges.
You keep hitting the same SI/CI question but can't find the pattern+
Immediate action
Identify the type: direct formula, find principal, find rate, find time, difference shortcut, or installment
Commands
Apply the corresponding formula from the list in the Solved Aptitude Problems section
Plug the numbers and check if the answer makes sense (e.g., SI for 2 years should be about P*R/100 * 2)
Fix now
If stuck, go back to basics: write down P, R, T, then decide if it's SI or CI. Then choose the right formula.

Common mistakes to avoid

5 patterns
×

Using half-yearly rate directly without adjusting time periods

Symptom
You plug R=10 and T=2 into CI formula but the answer is wrong when the problem says 'compounded half-yearly'.
Fix
Divide rate by number of periods per year (R=5) and multiply time by same number (T=4). Use A = P × (1 + 5/100)^4.
×

Confusing flat rate with reducing balance rate

Symptom
You think an 8% flat car loan is cheaper than a 10% reducing balance loan, but actually it's more expensive.
Fix
Convert flat rate to effective rate: for n-year loan, effective ≈ flat rate × (2n)/(n+1). For 5-year loan, 8% flat ≈ 13.3% effective.
×

Forgetting to subtract inflation when calculating real returns

Symptom
You celebrate a 7% FD return but after 6% inflation, real return is only 1%. Your purchasing power barely grows.
Fix
Always use real interest rate = nominal rate - inflation rate for long-term planning.
×

Using the Rule of 72 for rates above 20% or below 4%

Symptom
The estimated doubling time is off by more than 0.5 years, leading to financial planning errors.
Fix
For low rates (<4%), use ln(2)/ln(1+r). For high rates (>20%), use 69.3/r + 0.35 for better accuracy.
×

Assuming SI and CI are the same for short durations

Symptom
You dismiss the difference for a 1-year loan, but daily compounding still produces a noticeable gap (e.g., 36% daily vs 36% simple = ~7% extra).
Fix
Always check compounding frequency. Even for 1 year, daily vs annual compounding matters when the rate is high.
INTERVIEW PREP · PRACTICE MODE

Interview Questions on This Topic

Q01JUNIOR
What is the difference between Simple Interest and Compound Interest? Pr...
Q02SENIOR
How does compounding frequency affect the total interest? Derive the eff...
Q03SENIOR
Explain the Rule of 72 and its limitations. Provide a scenario where it ...
Q01 of 03JUNIOR

What is the difference between Simple Interest and Compound Interest? Provide formulas and an example.

ANSWER
Simple Interest is calculated on the original principal for all periods. Formula: SI = PRT/100. Compound Interest is calculated on the principal plus accumulated interest. Formula: A = P*(1+R/100)^T. Example: ₹10,000 at 10% for 2 years. SI = ₹2,000, total = ₹12,000. CI = ₹2,100, total = ₹12,100. The extra ₹100 is interest on interest.
N
Naren Founder & Principal Engineer

20+ years shipping production code across the stack, with years spent interviewing engineers. Written from production experience, not tutorials.

Follow
Verified
production tested
May 23, 2026
last updated
1,554
articles · all by Naren
🔥

That's Aptitude. Mark it forged?

13 min read · try the examples if you haven't

Previous
Permutations and Combinations
12 / 14 · Aptitude
Next
Work and Time Problems