Hello World! I'm talking about generating all possible combinations of a combination of variables. Let's suppose we wanted to flip a coin so we would have Coin1. And Coin2. We could just sort of do this in our head we can say Oh, they can both be heads, can both be tails, one head and the other tail, you know just do it in our head. But, let's do this systematically. And to show you the method that we're going to use here. The possible values for each of them are either heads or tails. Let's start them both at heads and that's the first combination. And then, I'm going to. Move this forward to the next possible value. Which is Tails. And. Leave this heads. And then I need to. This is the last value, so I can't move forward, so I'm going to go back to the beginning. And make this heads. And since I went back to the beginning here. I'm going to go to the next value. Over here. And then this one moves forward to the next. Possible value. Those are our four combinations. We have. Two possibilities for coin one. And two possibilities for coin two. That's two times two. Gives us four possible combinations. Let's do another example. And let's suppose we are rolling dice. So let's make this Die1. And this is Die2. The range of values. Is from 1 to 6. If I moved this forward to the next value or increment it. I get a 2 here. Since I was able to move forward. This one stays the same. Increment this. This stays the same. Increment this, this stays the same. 5. And one. This now becomes six. This stays one. But this is the end of my range of values. So for this next row I need to go back to the beginning for die2. Increment Die1. And then we have a two. And since we could increment that this stays 2. And. We go to 3 and this is still 2. And 4. Still 2. And 5 and we have a 2 over here. 6 is our last value. So in the next row we go back to one and increment this to 3. We will end up with 36 possible combinations of these die that's six possible values for die 1 * 6 for die 2 6 times 6 is 36. Possible combinations you can see this is just like counting. Just keep going with that. But sometimes we don't have a counting type situation. Let's call this variable 1 and variable 2. And variable 3. Let's suppose the possible values for variable 1 are True and false. and the possible values for variable 2 are A, B, C. And we have possible values of. 0 or 1. for variable 3. So we increment this to one.. The other two columns stay the same. I had said we could only have values of 0 or 1. for variable 3, so now we need to go back to the beginning. Since we went back to the beginning, we couldn't increment, we went back to the beginning, we moved this one to the next possible value and this one stays the same and then we have 1. And we were able to increment so this stays the same. And this stays the same. And then we have to go back to the beginning. And since we went back to the beginning we increment the next column over. And this still stays the same. And then we have 1. And we were able to increment it, so this stays the same. This stays the same. Now we go back to the beginning here. Go to this column to increment it, but we are at the last value, so we go back to the beginning here. And then we. Increment this to the next value. So, how many how many rows will we have in this tablre? Two possibilities here. Times 3 here, times 2 here, so 2 * 3 is 6 * 2, we should end up with 12. I'm going to just cheat a little bit here. This the next six are going to be just like. The first six except they'll be false instead of true. So I'm just going to copy and paste that down here. And I change this to true to false. Drag that down. To all those columns and there is my. 12 possible combinations of. Variable one which is true or false variable 2 which is A, B, or C and variable 3 which is a 0 or 1. And that's it. It's just like Counting.