#include <stdio.h> int main() { int a; printf("Enter The Value Of Integer : "); scanf("%d",&a); int b; b = a*(-1); if(a>0){ printf("\n %d Is The Absolute Value Of That Integer.",a); } if(a<0){ printf("\n %d Is The Absolute Value Of That Integer.",b); } return 0; }
Preview:
downloadDownload PNG
downloadDownload JPEG
downloadDownload SVG
Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!
Click to optimize width for Twitter