 Here's a program that prints a stage of life given an age. It's written as a series of independent unary if statements to test age ranges. Let's say I enter an age of 7. 7 is not less than 0, so I don't print that. 7 is not greater than or equal to 0 and less than 2, so I don't print infant. 7 is not greater than or equal to 2 and less than 4, so I skip the print on line 11. 7 is not greater than or equal to 4 and less than 6, so I skip the print on line 14. 7 is greater than or equal to 6 and less than 13, so I'm going to print out grade school. I continue on to the next if statement. 7 is not greater than 13 and less than 18, so I won't print teenager. 7 is not greater than or equal to 18, so I won't print legal adult. The only thing that I will print out is grade school and that's the correct thing. Let's run the script and view the shell and put in a 7 and sure enough it prints out grade school. There's nothing wrong with this program. It works exactly as advertised, but it could be improved. Notice that once we find out that the age is between 6 and 13, we don't need to do any of the other tests. This is a place where we'd like to use elses to save ourselves some computation. So let's rewrite it this way. If age is less than 0, that's not a valid age. Otherwise, let's test to see if it's greater than or equal to 0 and less than 2. If that's the case, we'll print infant. If that's not the case, then we nest yet another if statement and ask, well, is it greater than or equal to 2 and less than 4 and so on. I can nest my ifs inside of the else clauses and that will guarantee that only one of the ifs will be matched. There's some extra optimization that I can do here as well. If the age is not less than 0, let's say they entered 7, then I know for sure that it's not greater than or equal to 0, so I don't need this test at all. Similarly, if the age is 7, it's not less than 2, so I know it's greater than or equal to 2. In the else clause, there's no need for me to test that again. I could go through by hand and indent all of these, but to save a little bit of time, let me show you what this looks like when we're done. And here it is. Now if I enter a 7 for the age, it's not less than 0, 7 is not less than 2, it's not less than 4, it's not less than 6, but it is less than 13, which means we print grade school, and we skip this else, it's not needed. So our program is now a little bit more efficient. Let's run it and see that it works. Let's clear the shell, view it and run. And if the person is 7, they're in grade school. Again, the program works. There's nothing wrong with it. It's a little bit better than the previous version. The only problem we have now is that we're indenting and we're marching off the right-hand edge of the screen and it's hard to read and it could get confusing if we had more choices. There's a shortcut that you can use in Python. When an else is immediately followed by an if, you can combine them into the single keyword lif, and then I can unindent this. Here's another else that is followed immediately by an if, so I can combine those into lif and make sure my indentation is correct. The same with this else if can be combined into the keyword lif, and so on and so forth. Again, to save time I'm not going to do all of them. I'm going to show you what it looks like when it grows up. This is a lot more readable and it does the minimum amount of testing. Again, let's go with age 7. Is 7 less than 0? No. Well, otherwise if 7 is less than 2, which it isn't, otherwise if age is less than 4, otherwise else if age is less than 6, 7 is not less than 6, otherwise if age is less than 13, which it is, we print grade school, and then we can skip all the other lifs and elses. Let's view the shell, clear it, and run this version of the program, and again, a 7-year-old person is in grade school. The moral of the story, if you have a program with a chain of conditions, if some condition is true, otherwise if some other condition, otherwise if some other condition, otherwise if yet another condition, otherwise last case, you can take all the else ifs, and instead of having to indent them, you can combine them into lif, and then all your cases will line up nicely, your code will be more readable, and you can get away with a lot less computation to get the results you want.