tubeshowcase●1,116,245 videos♡ My collection 0
← Learn to Code

Learn to Code07:44

Let's code an interest calculator with C programming! 💰

Bro Code ↗

From the creator

#coding #programming #cprogramming // COMPOUND INTEREST CALCULATOR double principal = 0.0; double rate = 0.0; int years = 0; int timesCompounded = 0; double total = 0.0; printf("Compound Interest Calculator\n"); printf("Enter the principal (P): "); scanf("%lf", &principal); printf("Enter the interest rate % (r): "); scanf("%lf", &rate); rate = rate / 100; printf("Enter the # of years (t): "); scanf("%d", &years); printf("Enter # of times compounded per year (n): "); scanf("%d", &timesCompounded); total = principal * pow(1 + rate / timesCompounded, timesCompounded * years); printf("After %d years, the total will be $%.2lf", years, total); return 0;

Published 2025-03-10 · Watch on YouTube ↗
Availability and playback restrictions are controlled by the original channel.

Keep exploring Learn to Code