i don't understand about if-else | Sololearn: Learn to code for FREE!


i don't understand about if-else

I hope anyone will that anyone will help me

10/17/2019 1:54:34 PM

Rhohit Bojarajoo

4 Answers

New Answer


Rhohit Bojarajoo Please, Read the COMMENTS in the lessons you can find great examples and explanations.


Please explain where you are stuck else someone will end up explaining the same thing you have read and could not understand.


if is a statement that runs a block of code if its condition evaluates to true. else is a statement that follows an if statement and it runs it's code if if statement's condition evaluates to false. It does not much differ about how you would speak it. In C: if (50 > 4) { printf("50 is more than 4"); } else { printf("50 is not more than 4"); } In speech: if 50 is more than 4 print "50 is more than 4", otherwise print "50 is not more than 4".