Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
C code 1
#include <stdio.h>
#include <math.h>
int
main()
{
double xvalue, yvalue, abs_diff;
printf("Enter X Value: ");
scanf("%lf", &xvalue);
printf("Enter Y Value: ");
scanf("%lf", &yvalue);
abs_diff = (fabs(xvalue) - (fabs(yvalue)));
printf("The absolute difference is %2.2f\n", abs_diff);
return(0);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.