luc013.c
Problem Statement
luc013.c
Write a program to find the absolute value of a number entered through the keyboard.
Source Code
c
#include <stdio.h>
#include <math.h>
int main()
{
double num;
printf("Enter the number : ");
scanf("%lf", &num);
num = abs(num);
printf("\nAbsolute value of the input is : %g", num);
return 0;
}1
2
3
4
5
6
7
8
9
10
11
2
3
4
5
6
7
8
9
10
11
● Author - Amit Dutta · Updated - 12 Dec 2025