 So now we look at the major meat of this week, which is something known as the conditional statement And what we're doing is we're saying to Java now before you execute the next line of code I want you to actually take a look at some conditions some Decision needs to occur some logic needs to happen before you immediately do something and to do that we start off with the character or the Keyword if if like I said is just a keyword in Java that tells it before you execute anything Evaluate some expression first if that expression turns out to be true Do a block from the true section if it happens to be evaluated out as false do something in the false section so Let's say for example. We take a look at This statement right here. I've said make an integer x equals 42 the answer to life the universe and everything Well, if x is less than 50 again We're not worried about what this actually is. I know it's less than 50 But what happens in Java's sake is it needs to look at that it needs to actually do that comparison We as people we kind of nonchalantly are doing it in the back of our head The computer needs to be told to nonchalantly do it in the back of its head inside of the CPU So what happens is it'll go and it says if X is less than 50 now the same kind of thing that happened in left to the right association kicks in So instead of there being a left a memory address We don't really have that but we do have that right side the right equation the evaluation So what happens is this x? This x gets evaluated. What does this value mean? Well, it goes into memory grabs that value sticks it in there and suddenly it goes. Okay, is that value less than this value is 42 less than 50 Well, it'll evaluate this out and it'll become a boon. It'll either become either a true Or a false it can only become one of these two things because there is no gray area in program There's a yes or no true or false one or zero So in this case 42 is less than 50 and what will happen is I get into This this is my section that happens only if it's true only then Well, we can continue to think about this. What happens if instead of 142 I or instead of 42 I had given it the value of 142 142 is a little bit bigger and 142 is not less than 50. It's greater than again The program does not care about greater than it doesn't care about equal to all I asked it was is My x is my 142 now less than 50 true or false This again gets evaluated and because it's false goes down to this second else section Now this else section what occurs is after I've written my true block. That's how I have curly braces Indicating where the true statement begins and ends. I now need to deal with The what if the the it's not right. It's false And to do that I use the keyword else and again, I do the exact same thing. I throw a curly brace Around it to indicate that this is the false block It's everything that will happen if it is false and in our regard 142 is Not less than 50. So suddenly I go and I'll say a system dot out dot print L in greater than 50