Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- int main()
- {
- int a,s;
- float d,result,into;
- d=.5;
- printf(" Enter length = ");
- scanf("%d", &a);
- printf(" Enter weight = ");
- scanf("%d", &s);
- into=(d*a*s);
- printf(" The result is = 1/2 * %d * %d = %.2f \n", a,s,into );
- result=2*(into);
- printf(" The double of the result is = %.2f ", result );
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement