Welcome back.
Whenever you start to learn python it's unavoidable that you'll encounter this topic of Python 2 vs.
Python 3.
So what is this all about.
And it's a very important topic.
Now first of all python is created by a human right.
As a matter of fact it was created by this person right here.
His name is Guido.
Now a programming language is always evolving.
It sound like somebody creates a programming language.
It's perfect and that's it.
No.
All programming languages are constantly being updated.
Just like on your phone you constantly get software updates while a programming language is constantly
evolving to make it better and better because nobody gets it right the first time and by the way this
is a great video that I'm going to link to.
You can check it out in the resources.
Now Python was created in 1991 by this gentleman and it was actually created with the name from Monty
Python which was a British comedy group but like I said before the language is always evolving.
And in 2008 Brito decided that while python version 2 which has been used for a very long time had some
things that he and the community wanted to change.
So in 2008 they decided to create Python 3 a new version of the language.
Here was the tricky part.
You see when you update software lets say on your phone or even on your laptop you expect things to
keep working right.
Updates are usually good.
They're improvements but some of the features that Python 2 had they didn't like or they wanted to change
completely.
So Python 3 introduced to what we call breaking changes that is if you updated to Python 3.
Remember the Python interpreter.
The C Python translator that we've been talking about.
Well as soon as you updated that your Python 2 code wasn't really going to work.
It's like updating your phone and then all of a sudden all your apps stop working.
That doesn't sound very good does it.
That's pretty much what happened in 2008.
Most companies that wrote their code in Python Version 2 just kept python version 2 because well for
them to upgrade meant that they had to go through their code line by line and make some changes.
Now these changes weren't that significant.
For example I'll link to some resources but don't worry.
These are topics that we're going to cover throughout the course but different things wouldn't work.
For example the print function which we've learned about in python 2 It didn't have the brackets it
looked like this.
And Python 3 used the brackets.
So all the code that had print like this would break.
Now the differences themselves aren't that big.
I mean you can read through them and we'll talk about this in the course.
But overall you can learn them in a day.
That's why when we learn Python most of the time we're learning Python 3.
But you can use the same knowledge with the older version of Python Now you may see some python version
to code out there for companies that haven't upgraded but it's now will be called legacy that is come
2020.
It's going to stop receiving security updates so the community Python community as a whole is saying
hey everybody start using Python 3 because we're gonna stop maintaining Python 2.
So we're going to learn the most up to date version 3 in this course.
But we're also going to touch on some older topics that Python 2 covers just in case you encounter them
when you work for a company that perhaps still supports legacy code but as I mentioned the whole community
as a whole is moving towards Python 3.
This Web site for example shows you how many big packages popular Python packages which we'll talk about
support Python 3 in our case.
There's only four popular packages that don't support Python 3.
So what I'm saying is Python 3 is the way to go.
It's the way of the future.
That's what we're going to learn in the course.
But I want you to be aware of the historical context.
And one thing to be careful of when in this course you were searching for answers or maybe I have some
exercises that require you to Google things for example if we go to the Python documentation which is
the reference of how well what the programming language does you'll see that you can choose the versions
here and you always want to go with the latest but you might find some answers online that still use
python version too.
So you want to make sure that when you're searching for answers that you don't encounter any legacy
code.
Like I said 95 percent of the time it's mostly the same but you usually want to keep current with the
language it has the most community support most up to date most secure language.
So just a quick note about Python 3 versus Python 2 when you hear the word python.
People are generally just talking about both Python 3 and Python 2.
And if you remember in our reptile when we created our first program you see that you're using python
version three point six.
This is the default standard version that reptile concept.
So right away we know that we're using Python 3.
Awesome.
It's up to date.
It's new the whole community is behind it.
Well most of the community is behind it.
So we're all good to go.
I'll see in the next video by.