j

Tuesday, 3 November 2015

Write a program that take a, t and v from user and calculate the following fomula res=vt+0.5at^2



#include<stdio.h>
#include<conio.h>
void mian()
{
clrscr();
int v,t,a;
float res;
printf("Enter the values of a, t and v ::");
scanf("%d%d%d",&a.&t,&v)
res=(v*t)+(0.5*a*t*t);
printf("The result is %f",res);
getch();
}

Subscribe to this Blog via Email :