Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include<stdio.h>
- int main()
- //math problem
- {
- double x,y,xpy,xmy;
- printf("enter the value of x+y:");
- scanf("%lf",&xpy);
- printf("enter the value of x-y:");
- scanf("%lf",&xmy);
- x=(xpy+xmy)/2;
- y=(xpy-xmy)/2;
- printf(" x= %0.2lf ,y=%0.2lf",x,y);
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement