Python program to find compound interest

1627
Python program to find compound interest
p=float(input("Please enter principle amount: "))
t=float(input("Please enter the time in years: "))
r=float(input("Please enter the rate of interest: "))
ci=p*pow((1+r/100),t); #gives compound amount, interest with principle amount
print("\n compound amount is: \n",ci);
ci=p*pow((1+r/100),t)-p; #gives only compound interest */
print("\n compound interest is:\n",ci);

     Output:
     Please enter principle amount: 5000
     Please enter the time in years: 3
     Please enter the rate of interest: 4

     compound amount is: 
     5624.32

     compound interest is:
     624.32

 

 

 

Python program to find compound interest write a python program to find compound interest write a program to find compound interest in python write a program to find compound interest write a python program to find out the compound interest write a program to find out the compound interest in python write a program to find out the compound interest python program to find the compound interest program to find the compound interest program to find compound interest in python