Header Ads

programming language C

Solve:

5. Write a program to calculate the compound interest principal amount P rate R for N years.

Ans:-/* programming to find compound interest */
         # include < std io .h >
         # include < con in .h >
         void main ( )
         {
          float p,r,n,c,i;
          clrser ( );
          print of ("enter principal amount ;rate and year \n");
          scan f   ("%f%f%f,"&p,&r,&n);
          ci =p* pow { (1+r 100),n} =pi
          print f ("compound interest =%f\n",ci);
          getch ( )
                      } 

No comments

Powered by Blogger.