 Hey everybody, this is Brian and welcome to the first Python tutorial. I've been wanting to do Python for a while, I should dispel a few myths first. Everybody hears the word Python and they think this big evil monster snake and I mean even the icon for it is like these two snakes in a ying-yang symbol. So everybody thinks of this little guy right here. It's actually not the case. Python's been around for a long, long time and it was actually named after the Monty Python. If you have no idea who Monty Python is, I feel very sorry for you and you should Google it because they're hilarious. Their comedy is actually timeless. But it's the whimsical nature of Python. It's the language that's tried to emulate that. So if you go to python.org, we'll be working with the newest version, Python 3.43, that may actually date this video at some point if they drastically change Python. But you'll see it's available for Windows, Mac, Linux and pretty much everything in between and it even comes with full source code. Some things you should know about Python before we get started is they really say batteries include this kind of the lingo here for Python and that's, I've got to agree with it. It's very powerful and it's not very chatty and what do I mean by chatty? Some programs you have to write hundreds of lines of code just to print something on the screen. Python, it's just dirt simple. And if you're in a university, a lot of universities are actually replacing Java with Python as the learning language. So I wanted to kind of get into it. I have a heavy security background and Python has actually become the language of choice among hackers. Not all hackers, but a vast majority of them love Python because it's just very easy to work with and very powerful. Python does come with a built-in IDE called idle, which I personally cannot stand, especially for teaching purposes. So I'll be using JetBrains PyCharm. If you've watched any of my tutorials, you know that we just, you know, take the seat belt off and just dive head first in and I'm going to kind of slow it down a little bit because I realize that being an introductory language, especially being taught at universities and some of my videos are actually shown at universities, I want to kind of dumb this down as if this was your first programming language. Now, that disclaimer being said, I am not going to hold your hand through this whole process. We're going to take our seat belts off and dive right in. So let's just go to it, maybe, if I can find PyCharm. There we go. So we'll load up PyCharm. I'm using the Community Edition 4, which is absolutely free, and I'm just going to kind of move the window out here. I should note that you're going to need Python installed before you do this, and you'll know because if you go to create a new project and you don't get a Python version here, then you need to do something about that. And what you do is you go out to python.org, download the version that's right for you. If you're on Windows, it's just a normal install or click next, next, and you're done. If you're on a Linux, Unix, BSD, Mac, whatever derivative, you're going to actually have to compile it by doing slash configure. And if you've done this before, you've done this a million times, you just go into the directory, you do slash configure, make test. Make test on my machine actually failed, but then you do sudo make install. It actually installs it as Python 3. So you can open a command line here and you'll notice if I just type Python, it says Python 276, which is the older version. So I'm going to control D out of there. I'm going to do Python 3. And there's 343, that's the version we'll be working with right here. So just bear that in mind if you have the old version of Python, you'll want the new version for these tutorials. And when I say old and new, I should really explain that when you go out there, and let's actually just rewind here a minute, when you go out to Python, you go to downloads, you'll see, you get the option between 34 and 279. The reason is back in, I want to say somebody out there will correct me if I'm wrong because the internet's full of experts, but it's like Python 2.5. They actually made a radical change to the Python libraries. I shouldn't say radical, radical enough that it broke legacy code. So they've kind of branched it off here. So they've got the old version of Python and the new version of Python. And there's some gotchas. So if you try to use my code with the old version, it just simply won't work because it doesn't understand what you're trying to tell it. So just bear that in mind, you'll need the newest version. Why am I starting off with the newest version? Well, eventually the old Python will get phased out and render my tutorials useless. So what's the point of wasting my time in yours? All right, so once you've got Python set up, if you're kind of like a little computer nerd like me, you're going to want to look and see what's in here. And you'll see there's the Python binary. And there's all the little files that it created. Pretty awesome, huh? And if you go out to use your local bin, you'll actually see there's the the symbolic link for Python 3. Jumping back into PyCharm here, we're just going to pick the newest version. We're going to call this videos. Why not? And hit create. And ta-da! There's PyCharm and all its glory. I'm going to resize this a little bit here. Now I know I'm probably going to get a million messages saying why are you using PyCharm? There's better IDs out there. You know, I tried a few of them and I wasn't impressed with a couple of them. So I just, I really like PyCharm. I don't know what it is. I'm not in any way affiliated with their company at all. I haven't even bought the product. I just really like the ID. All right. So first thing we're going to do is make a Python file. And we're going to call this, hmm, we need a descriptive name. Let's call it video1 because this is our first video. And you see this author root shell. Well, that's my username on my computer. So I'm going to change that for future tutorials. And it puts that in there automatically for you. Now we are going to do the obligatory hello world program. And what do I mean by obligatory? In every language, your first introductory program is hello world where you literally just print hello world on the screen and it's this big awe inspiring thing and there's harps and kittens and rainbows and don't expect fireworks. It's actually pretty fast in this one. You just do parentheses and then quotes hello world. And we are going to actually right click here and run video1 and you'll see down here hello world. And that's actually why I chose pie charm because it's very easy to see what's going on. There's no magic behind the screen and you can see everything that's going on here. And if there's an error, it'll print it out, you know, pretty plain English here. If you try this and you get an error message, it's because you're running the old version of Python, which is expecting something like this hello world, which as you can see, it's saying, hey, you know, end of statement expected. Now, if you don't know what a statement is or any of that, you're very new to computers. Don't worry, we're going to cover all this in future tutorials. That's it for this tutorial. Like I said, painless, no fuss, no muss, we're going to dive into these head first and you really should go out to my website voidrealms.com and click on tutorials and it's not there yet. But I will add a Python folder in here and the source code for this and all the other tutorials I've done are out here. Also visit Facebook and join the void realms Facebook group. There's like 200 programmers in there. So if you have questions, instead of emailing me and waiting six months for me to find your email, it's much easier just to say, hey guys, I got a question. Thanks for watching. I hope you found this educational and entertaining.