 Welcome back everybody. This is Brian. We're going to continue our journey with Python 3 whatever IDE you're using create a blank file I've got my name Python 3-3 at this point the name is not important Just have a blank file ready to go. We're going to cover three key things Comments bullions and comparisons. Let's dive right in Okay, comments. You've actually seen them, but we haven't really talked about them What is a comment without writing any code? Go ahead and run your script. You see it does absolutely nothing We're going to hit the pound sign and just type something. This is a comment So really what does this do? Well, if we run our program, you'll see nothing's changed. It does absolutely nothing a Comment is just that it's a comment on the code It exists solely for you the programmer so you can keep some sort of notes So for example, you can say this is our third video And you notice how you can add in letters numbers, whatever you want And it's not gonna throw any sort of error message when we run it. This is strictly for you This is your note now if you're coming from another programming language You're probably hoping there's a multi-line comment meaning if you have a few lines like Hello world I like cats You notice how as I was typing it tried to help me out and it put what we call IntelliSense in there, which is code that's already pre-written for us Well, we really didn't want that so it just caused all sorts of errors Now if I were typing in a comment, I'd say hello world. I Like and you notice how IntelliSense suddenly is not really popping up I can force it pop up by hitting control in space But it doesn't really know what we're doing because we're in a comment Multi-line comment would be like if you had and I'm just going to grab some text here This is not a comment even though it says it is a comment It's really not if we try to run it. Oh you see invalid syntax Because it's trying to interpret this as code now we can put a pound sign in front of each one of these For example, let's just go this one and this one This one and it's going to get really dull if you got like a hundred lines you need to do So what a lot of Python developers will do is This they'll just have triple quotes and anything inside the triple quotes becomes a string String something we're going to really talk about in depth in another video. Just know that this is a data type So we're not truly making a comment. We're making a string But the string does absolutely nothing. So if we run that again, there's no error message And let's clear that nasty error out just so you can see You can run this all day long and there's no error message But we have created a variable believe it or not So I do not favor this and be a little careful. This might cause issues later Especially if you get into like doc strings and things like that which we're going to cover later on in this series So you may be asking What is the functional purpose of a comment? Well It exists solely for you the developer as a note You can also enable and disable code using a comment. So for example, let's just say x equals one print x You can see it is now printing one we could change this to Hello world, which we did in a previous video and there's hello world now if we comment this out This x technically no longer exists and you see it's giving us a little red squiggly line It's saying undefined variable and if we try to run this you guessed it. Boom name x undefined So we can disable this code by commenting it out We can re-enable it by simply deleting that pound sign So let's cover our first real data type here and this is very fundamental. It's called a bully Some people just call it a bull for short And it is a true or a false think of it like a light switch like physically look at the light switch in your room It's either on or off and that's really what this data type signifies So let's make a few. I'm gonna actually comment out this code and Let's make some I'm going to say x equals true Notice how it has a capital T and IntelliSense is trying to help us out by saying hey, it must be capital and y equals false again capital F You may be tempted if you're especially coming from another language to give it a data type like this You do that bad things are gonna happen. It's not gonna know what you're trying to do We can actually try to run this and you'll see what I mean But invalid syntax, so it's not understanding what's going on when we get rid of that Suddenly magically it works You hear that error out so it doesn't confuse anybody Again, these are case sensitive so if I change that to a lower case You see how IntelliSense no longer has that as blue and we're gonna get a nasty little issue if we try to run this Name true is not defined. Remember when you see is not defined That's the interpreter's way of saying hey, I have no idea what you're trying to do here Simply because it does not exist So let's switch this back to a capital T and life is good So I'm gonna just copy and paste some notes in here Notice how you can put a comment on its own line or after if you put it before for example If I move this right here it turns everything after it on that line into a comment So be very careful doing that and these comments have absolutely zero impact on our code For example, we can run this all day. There are no error messages Then clear this out now that we have that Understand that we want to do some fundamental comparisons, which is what we're gonna talk about next Okay, let's talk about comparisons first off. What is a comparison? Well, it's the building block towards programming logic So comparison is the building block of logic Meaning we want some value Take that value and compare it to another value to see what we need to do with the programming logic here For example, I'm just going to print out X and Y. I'm gonna do this a little bit differently I'm gonna put the letter F which stands for formatting And I'm gonna say X equals brackets and then X Looks a little confusing, but really all we're doing is saying print out X but do it in a fancy manner See X X now I can change this to Y And it becomes very simple to understand what's going on X is true Y is false. We're gonna compare these two now So the very first comparison we're gonna do is equal and it's actually pretty straightforward. So I'm just gonna grab this and Let's say Equal We're gonna do our logic here and we're gonna say You have to be a little careful when you do an equals because if you just do this You're actually assigning. These are called operators. This is the assignment operator. We're now saying X equals Y We don't want to do that. We want to compare it. So we're gonna say X is equal to Y We're simply comparing Then let's say the opposite of that. I want the not equal Notice it's an exclamation whenever you see the exclamation think exact opposite of what you want So we want is this the opposite of equal or Not equal. Let's go ahead run this see what happens here You can see X is true Y is false. They are not equal to each other and it is giving us a true when we test for inequality It's actually pretty cool that we can do that We know virtually nothing about programming at this point in this series But we already have the foundations of computer logic true and false and we can test for those conditions Let's take this a step further here. And what we're gonna do is Greater than and greater than or equal to so I'm gonna just grab one of these and I'm going to say greater than very very simple We're gonna say print out is X greater than Y Now I want to say greater than or Equal to Very similar syntax to the not equals to we're saying greater than equal to and Let's do the exact opposite. Let's say less than and let's flip these around Let's go ahead and run this and you can see there we go Greater than true greater than or equal true less than false less than or equal false These admittedly won't make a lot of sense to you right now until we start talking about the numbers Which we're gonna talk about in the next video But for bulls know that equal and not equal are great and these are the building blocks of logic We can start doing flow control now, which would be things like if then for example, if you're hungry go eat Otherwise go do something else. We're gonna talk about all this in future videos, but really nail down the fundamentals here What we're really talked about is comments. They are your buddies they're your friends be kind of careful how you do those comments and Bullions these are simply on or off true or false. Remember these have to be case sensitive And we've covered some foundational comparisons. For example, we're saying equality inequality Greater than greater than or equal to less than and less than or equal to I Hope you enjoyed this video You can find the source code out on github.com if you need additional help myself and thousands of other developers are hanging out in The void realms Facebook group. This is a large group with lots of developers and we talk about everything technology related Not just the technology that you just watched and if you want official training, I do develop courses out on you to me Com this is official classroom style training if you go out there and the course you're looking for is just simply not there Drop me a note. I'm either working on it or I will actually develop it I will put a link down below for all three of those and as always Help me help you smash that like and subscribe button the more popular these videos become the more I'll create and publish out on YouTube. Thank you for watching