HollerTrain HollerTrain - 11 days ago 6
C Question

What are the differences between if, else, and else if?

I am trying to discern the difference between

if
else
else if


When do you use them and when not?

I have a homework assignment with a ton of instances and I am running into code error due to not knowing the differences between each.

Can someone please define how to use these?

Answer
**IF** you are confused
 read the c# spec
**ELSE IF** you are kind of confused
 read some books
**ELSE**
 everything should be OK.

:)

Comments