- ceil( ) function in C returns nearest integer value which is greater than or equal to the argument passed to this function.
- ”math.h” header file supports ceil( ) function in C language. Syntax for ceil( ) function in C is given below.
double ceil (double x);
Example program for ceil() function in C:
#include <stdio.h> #include <math.h> int main() { float i=5.4, j=5.6; printf("ceil of %f is %f\n", i, ceil(i)); printf("ceil of %f is %f\n", j, ceil(j)); return 0; }
Output:
ceil of 5.400000 is 6.000000 ceil of 5.600000 is 6.000000 |
Very informative article.Thank you author for posting this kind of article .
ReplyDeletehttp://www.wikitechy.com/view-article/ceil-function-in-c-language-with-example-and-explanation
Both are really good,
Cheers,
Venkat
How To Turn Off Suggested Posts On Instagram Feed
ReplyDeleteHow To Turn Off Suggested Posts On Instagram Feed
How To Get Emojis On Chromebook
ReplyDeleteHow To Get Emojis On Chromebook