This is where the branching comes in. Branching is very common when you are dealing with input to your script. Most programs take some sort of input, do something with it, and then produce an output. In our script, the input is the user name, and the output is the greeting message that we display. The thing is that input is usually very unpredictable. We don't know what the user's going to do when they see this dialogue box asking for his name. Will they enter their real name? Will they enter their name at all? Will they be offended and just click the Cancel button? Will they try and be cute and just hit the space bar a few times before clicking the OK button? You just don't know.
First
Next