কম্পিউটার টিউটোরিয়াল

C প্রোগ্রাম: চক্রবৃদ্ধি ব্যাজ গণনা


এখানে আমরা দেখব কীভাবে একটি সাধারণ C প্রোগ্রাম দিয়ে চক্রবৃদ্ধি ব্যাজ বের করা যায়। লজিকটি খুব সহজ। এখানে কিছু প্যারামিটার দরকার −

  • P − মূলধন (Principle amount)
  • R − ব্যাজের হার (Rate of interest)
  • T − সময়কাল (Time span)

চক্রবৃদ্ধি ব্যাজের ফর্মুলা নিচের মতো −

C প্রোগ্রাম: চক্রবৃদ্ধি ব্যাজ গণনা

উদাহরণ

#include #include float compoundInterest(float P, float T, float R) { return P*(pow(1+(R/100), T)); } int main() { float p, t, r; printf("Enter Princple amount, rate of interest, and time: "); scanf("%f%f%f", &p, &r, &t); printf("Interest value: %f", compoundInterest(p, t, r)); }

আউটপুট

Enter Princple amount, rate of interest, and time: 5000 7.5 3 Interest value: 6211.485352

  1. C প্রোগ্রাম: সমান্তরাল চতুর্ভুজের পরিধি (Circumference) বের করা

  2. C-এ ক্রিসমাস ট্রি প্রিন্ট করার প্রোগ্রাম (এনিমেশন সহ)

  3. পাইথনে চক্রবৃদ্ধি বunga (Compound Interest) প্রোগ্রাম

  4. পাইথন প্রোগ্রাম: সিম্পল ইন্টারেস্ট ক্যালকুলেশন