Quote:
Originally Posted by Stewartmiddlemagnetschool
what is the diffrence between if the and if else please responde asap
thanx
|
I'm not sure what you mean by "if the" However, here is the explanation that you probably need.
The if-else construct looks something like this in pseudocode:
if(something is true){
do a particular thing
} else, meaning that it is not true{
do something different
}
In most programming languages, you can leave the else-clause off leaving only the if-clause. In that case, the meaning is something like the following:
if(it is not raining){
play baseball
}end of the statement
In Alice, you can't leave the else-clause off. However, you can leave it empty, which is functionally the same as leaving if off.
Perhaps you need to spend some time with the free online Alice tutorials listed below.
Dick Baldwin
Free Alice tutorials:
http://www.dickbaldwin.com/tocalice.htm
Free programming tutorials:
http://www.dickbaldwin.com/toc.htm