Social Icons

Wednesday, 19 March 2014

C Program to convert fractional value to its nearest value

#include<conio.h>
#include<stdio.h>
#include<math.h>

main()
{
clrscr();
{
float n;
float s;
printf("\n Enter a Fractional Number : ");
scanf("%f",&n);
s=ceil(n);
printf("\n Nearest value is : %f",s);
}
getch();
}


                                                          OUTPUT

No comments:

Post a Comment