All language subtitles for 007 Running Python Code using the Python Interpreter_en

af Afrikaans
ak Akan
sq Albanian
am Amharic
ar Arabic
hy Armenian
az Azerbaijani
eu Basque
be Belarusian
bem Bemba
bn Bengali
bh Bihari
bs Bosnian
br Breton
bg Bulgarian
km Cambodian
ca Catalan
ceb Cebuano
chr Cherokee
ny Chichewa
zh-CN Chinese (Simplified)
zh-TW Chinese (Traditional)
co Corsican
hr Croatian
cs Czech
da Danish
nl Dutch
en English
eo Esperanto
et Estonian
ee Ewe
fo Faroese
tl Filipino
fi Finnish
fy Frisian
gaa Ga
gl Galician
ka Georgian
de German
el Greek
gn Guarani
gu Gujarati
ht Haitian Creole
ha Hausa
haw Hawaiian
iw Hebrew
hi Hindi
hmn Hmong
hu Hungarian
is Icelandic
ig Igbo
id Indonesian
ia Interlingua
ga Irish
it Italian
ja Japanese
jw Javanese
kn Kannada
kk Kazakh
rw Kinyarwanda
rn Kirundi
kg Kongo
ko Korean
kri Krio (Sierra Leone)
ku Kurdish
ckb Kurdish (Soranรฎ)
ky Kyrgyz
lo Laothian
la Latin
lv Latvian
ln Lingala
lt Lithuanian
loz Lozi
lg Luganda
ach Luo
lb Luxembourgish
mk Macedonian
mg Malagasy
ms Malay
ml Malayalam
mt Maltese
mi Maori
mr Marathi
mfe Mauritian Creole
mo Moldavian
mn Mongolian
my Myanmar (Burmese)
sr-ME Montenegrin
ne Nepali
pcm Nigerian Pidgin
nso Northern Sotho
no Norwegian
nn Norwegian (Nynorsk)
oc Occitan
or Oriya
om Oromo
ps Pashto
fa Persian
pl Polish
pt-BR Portuguese (Brazil)
pt Portuguese (Portugal)
pa Punjabi
qu Quechua
ro Romanian
rm Romansh
nyn Runyakitara
ru Russian
sm Samoan
gd Scots Gaelic
sr Serbian
sh Serbo-Croatian
st Sesotho
tn Setswana
crs Seychellois Creole
sn Shona
sd Sindhi
si Sinhalese
sk Slovak
sl Slovenian
so Somali
es Spanish
es-419 Spanish (Latin American)
su Sundanese
sw Swahili
sv Swedish
tg Tajik
ta Tamil
tt Tatar
te Telugu
th Thai
ti Tigrinya
to Tonga
lua Tshiluba
tum Tumbuka
tr Turkish
tk Turkmen
tw Twi
ug Uighur
uk Ukrainian
ur Urdu
uz Uzbek
vi Vietnamese
cy Welsh
wo Wolof
xh Xhosa
yi Yiddish
yo Yoruba
zu Zulu

Original subtitles

Hi, and welcome back.

In this video, I'll show you how to run or execute Python code using the interpreter.

There are several ways.

And we'll take a look at each of them.

If you want to test some basic concepts or execute just a few Python instructions.

You can write an execute them directly in the python interpreter.

Here you have two options.

The first option is to open the interpreter from the Windows Command line or cmd dot TCS and write all

the Python instructions there.

Even if this works perfectly, it isn't the recommended way, or at least not for beginners.

That's because it lacks the advanced features like auto completion or a color highlighting of key words

or errors.

It will be harder for you to write your code here.

However, this is how it's done.

Go to start type CMD and hit enter.

Now I'll write the python and press the enter key.

The python interpreter has just started.

Here we can execute Python instructions.

The second option to execute Python code using the python interpreter is to use idle, which stands

for Integrated Development and Learning Environment.

On Windows Idol comes by default with the Python installation, so it's already there.

To open idol just type idol in the Windows Linux or Mac Start menu.

And you'll see something like this.

This is a python shell or interpreter where you can write and execute short scripts and see their output

immediately in real time.

Each line starts with a three greater than size.

This is the ideal command prompt.

Throughout this course, when we say three greater than size will know that the code has been executed

in Python idle.

Let's write something very simple.

Print and the Hello Python in parentheses and double quotes.

Now let's do something else.

X equals six x times two.

What have I done?

I've just declared a variable called X that is equal to six and then printed out x times two.

In Python idle.

It's not necessary to use the print function to see the value of a variable.

You can just type its name and hit enter.

We won't focus right now on variables or other Python programming concepts.

We'll have a lot of time for that in the next lecture.

For the moment, I just want to show you how to execute Python statements in idle.

If you want to execute a statement again, you simply go with the arrow keys to that line and press

the enter key.

And we can see how that statement has been copied on the last line.

I can modify it and run it again if I want.

Another useful feature is the autocomplete or word completion.

The application will predict the rest of the world a user is typing.

This time I'll declare another variable that stores a string, which is a sequence of characters name

equals and between double quotes.

Andre.

And then I'll write the name and the date.

And I'll wait.

Idle will open up a pop up window with all the methods and attributes available to the string objects.

Let me say it again for the moment.

Don't focus on the language, but only on Python idle.

You can change the completion, pop up, wait time by going to options, configure idle and the windows.

Shares the completion of pop up wait time, which is given in milliseconds.

Other options like the font size can be changed in this window to.

Also keep in mind that you can run many simultaneous sessions of Idol as you want without one interfering

with the other.

I'm opening another idle session.

They are completely separated working environments.

In our course we use idle only for small tasks and examples for complex scripts Picture, which is probably

the most used professional python ID will be our choice.

I'll show you how to run your scripts in picture in the next video.

I'll see you soon.

Can't find what you're looking for?
Get subtitles in any language from opensubtitles.com, and translate them here.