 Hey, what is going on guys root of the knell here come back at you with some more batch tutorials? I'm gonna get the windows command line fired up I'll bring this right down to you guys can see it and we'll start working now in this video I want to introduce another pretty easy and simple to understand Concepts to you guys because we're still early on in the series and we have to knock these things out of the water before We jump into more advanced more difficult topics But here what we're gonna be looking at is something called a variable and a variable is actually something that will store Information or data that we're trying to work with inside of our program or script now you saw in the last video we were looking at data types and the sort of naming or the the format the They sort of like the understanding or the form of the data that we're trying to sort We had numbers we had like really in that case We had integers and floating point numbers and then we had text which was really like a string or a character So let's try and apply this what we're gonna do is we're gonna create a variable now a variable is just something that Stores that information it can equal equal anything and the thing is it's called a variable because it tends to vary We can change what this thing might actually equal or actually represent and we may not even know what it represents If we had if we stored the user input or what the user was actually typing into the program if we turn that into a variable We may or may not know what they typed in but we still need to be able to work with it inside of our program So that's why it's called a variable and let's go ahead and create one I'm gonna call mine var name. We can call it absolutely anything if we wanted to we could call it Doug We could call it Tom we could call it X if we really wanted to like we're working in algebra But to keep things simple for your guys for you guys in a way I'm gonna call mine var name and now we use the equal sign here, which is an assignment operator We're actually assigning something to this To this variable here and let's say var name is equal to howdy now Howdy is a string remember we're typing in text for it here But we don't want to actually use these quotation marks because if we did you'll they'll actually interpret them I'll show you in a few moments But let's go ahead and hit enter and let's show you what we're working with here var name is equal to howdy But we're gonna get an error because var name is not recognized as an internal or external command Offer it a programmer batch file because it's going to go right It's gonna run right through the string that we've typed into the prompt We're typing in the command and when we get to var name it's going to try and execute var name But var name really isn't a program. It's the variable that we're trying to create So in batch you have to actually use a specific Command or statement to actually create a variable and in our case. This is called set S-e-t now following set we're going to say var name and we're going to set it to equal howdy And that that runs without a problem awesome. So var name is now stored And we can call it back and we'll retrieve the value that it stores in our case howdy So let's go ahead and do that the way we do this in batch is a little is a little different We have two percent signs and in between them We type in the actual name of the variable the variable that we created So percent sign var name percent sign now when we hit enter Howdy is not recognized as an internal or external command offer a little programmer batch file Now you can see what we're doing here. Obviously howdy really isn't a command But because var name is equal to howdy when we replace this part here The the var name wrapped into two percent signs. It's expanding that variable. It's replacing The actual name with what it really represents in our case howdy So it's trying to run howdy because it's being replaced with there But it isn't a program or anything else So, uh, let's try this with those quotation marks down now. Let's start set var name We can set it to equal. Oh, sorry set var name equal howdy And now when we try and type this out if we do var name It'll give us howdy with those quotation marks in there So it's not interpreting them even though it this is a string It's still going to interpret those quotation marks, but we don't really want that So in our case, we're just going to use it plain old and simple without those quotation marks And it'll interpret it as it'll interpret it as a string no matter what So, uh, really that's all I wanted to show you guys in this video though You I hope you guys were able to understand the concept of setting variables so we can set set variable to be Equal anything And now you're going to want to use those two percent signs around your variable name to actually get the contents or what that variable actually represents So in our case anything and we can't really run that So, uh, really that's all for you guys. I hope you enjoyed that We're going to be working with variables a whole lot because they really are the core and the fundamental of programming Uh, without them, we wouldn't be able to create anything versatile We really wouldn't be able to store the information that we're working with and it would just plain old suck So, uh, that's all for you guys though. I hope you enjoyed this and I will see you in the next tutorial