Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- int main()
- {
- int x,y,sum,difference,product,quotient,remainder;
- printf("Enter first number:\n");
- scanf("%d",&x);
- printf("Enter second number:\n");
- scanf("%d",&y);
- sum = x+y;
- difference = x-y;
- product = x*y;
- quotient = x/y;
- remainder = x%y;
- printf("Sum of x and y value is %d\n", sum);
- printf("Difference of x and y value is %d\n", difference);
- printf("Product of x and y value is %d\n", product);
- printf("Quotient of x and y value is %d\n",quotient);
- printf("Remainder of x and y value is %d\n",remainder);
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment