find simple interest & compund interest
Answers were Sorted based on User's Feedback
Answer / chakkra
#include<stdio.h>
#include<conio.h>
main()
{
float p,n,r,samt=0,camt=0;
printf("enter the principle, no. of years & rate of
interest");
scanf("%f %f %f",&p, &n, &r);
if(p>0&& n>0&& r>0)
{
samt=(p*n*r)/100;
camt=p(1+r/100)^n;
printf("simple interest amount:%f",samt);
printf("compound interest amount:%f",camt);
}
}
| Is This Answer Correct ? | 8 Yes | 6 No |
Answer / praveen kumar singh
#include<stdio.h>
#include<conio.h>
#include<math.h>
void main()
{
float p,n,r,si,ci;
printf("enter the value of p,n,r");
scanf("%f%f%f",&p,&n,&r);
si=p*n*r;
ci=p*(1+r/100)^n;
printf("si and ci is%f%f",si,ci);
getch();
}
| Is This Answer Correct ? | 5 Yes | 5 No |
union u { struct st { int i : 4; int j : 4; int k : 4; int l; }st; int i; }u; main() { u.i = 100; printf("%d, %d, %d",u.i, u.st.i, u.st.l); } a. 4, 4, 0 b. 0, 0, 0 c. 100, 4, 0 d. 40, 4, 0
Given a spherical surface, write bump-mapping procedure to generate the bumpy surface of an orange
main() { int i=400,j=300; printf("%d..%d"); }
main() { int i=0; for(;i++;printf("%d",i)) ; printf("%d",i); }
how to concatenate the two strings
#include<stdio.h> #include<conio.h> void main() { int a=(1,2,3,(1,2,3,4); switch(a) { printf("ans:"); case 1: printf("1");break; case 2: printf("2");break; case 3: printf("1");break; case 4: printf("4");break; printf("end"); } getch(); }
There are 21 people in a room. They have to form groups of 3 people each. How many combinations are possible? Write a C program to print the same.
PROG. TO PRODUCE 1 1 1 1 2 1 1 3 3 1 1 4 6 4 1
Give a one-line C expression to test whether a number is a power of 2.
print a semicolon using Cprogram without using a semicolon any where in the C code in ur program!!
35 Answers Tata Elxsi, TCS, VI eTrans,
Write a program to print a square of size 5 by using the character S.
What is the difference between proc means and proc tabulate ? explain with a simple example when you have to use means or tabulate?