< Prev
Next >


If-else Statement





In C language's if-else statement, the condition in the parenthesis of if is evaluated for a boolean value - true or false.






if else example


 /* C - if else example */


#include<stdio.h>
int main()
{
if(100<50)
	printf("100 is less than 50");
else
	printf("100 is greater than 50");
	
return 0;
}


Output -

100 is greater than 50 


Please share this article -

Facebook Google Pinterest Reddit Tumblr Twitter




< Prev
Next >
< If Statement
Else-If Statement>
Please subscribe our social media channels for notifications, we post a new article everyday.

Decodejava Google+ Page Decodejava Facebook Page  DecodeJava Twitter Page

Coming Next
-
C++ and Python

Ad2