Welcome back again. We are going to write our first program. How exciting is that? Yay. Okay, so hold on to your seats. We're getting ready to write our first program is going to be a very, very, very, very, very simple one.
Okay, so we installed Python already. Let's click on our little button there. Let's bring our idle proton Python up. I'm going to click on that. And then again, it's going to open in that beautiful little edit window. So just follow along with me if I go a little fast, you can always pause you can back it up.
Do whatever it is that you need to do, but make sure you type it exactly as I type it. The first word we're going to type is print. Make sure you do not misspell this because print is a imbedded Python command it comes with the program. So it already has functionality to it. So we're going to type print, if we misspell this, it is not going to work. Okay.
Anything that we are going to print to the screen and we want our users to see needs to be in parentheses, and it needs to have a quote around it. So let's do parentheses really quick. And then let's do our quotes. I'm just going to use a single quote. And in that, I'm going to type python programming is so fun, exclamation point. And that's it.
That's all we have to put because that's all we're going to do. Print. We have to use our parentheses and we have to use single quote. Python really doesn't care if you use single quotes or double quotes, but you have to use one or the other. You can't start it off with a single quote and end with a double quote or start off with a double quote and end with a single quote. So you just need to make sure that your quotes are the same throughout.
So we use the print function, we put in parentheses because we have what's called a string value. And we are in a quote, and we typed python programming is so fun. So perhaps I've typed or talked long enough that you've got all that typed in. So now that we have it all in there, what do we have to do? Well, we have to run it. So up here at the top, if you look, it says run.
Click on that and then click Run module. The other thing you can do is you can see right here, there is an f5 list an extra one Module. So if you get tired of clicking and clicking and clicking, you can just push us by f5. And then it will automatically run. So we're just going to click on Run module. Before you can run it, it must be saved.
So you're going to click OK to save it. You can save it wherever you want to save it, that's up to you. For me, I might like to save it in my documents. Give it whatever name you want, just you know, try to make sure it's relative to the program that you're writing so that you know what it's for. Click Save. And then once it's saved, it's going to run and this python shell window pops up.
And now you can see it says python programming is so fun. And that is what the users are going to see. Whenever the pro Ram is run. They don't see the print command. They don't see the quotes and they don't see the parentheses. What a quick lesson we wrote our first program.
So pat yourself on the back. You did a great, great job. See in the next lesson