You are viewing a single comment's thread from:

RE: def learn_python(world): print “hello” + world. Learning to code #1

in #steemdev7 years ago (edited)

From screen shot I'm assuming that codecademy uses Python 2.7.

print "something" # Python 2.7
print("something") # Python 3+

As someone just starting (just like me) I'm suggesting you to start learning newer Python version.

2.7 is slowly leaving. And there are certain newer things that are not being supported any more. There is absolutely no reason to start learning something that is being outdated.

I deliberately skip any tutorial that uses 2.7 it is just not worth it in my opinion.

P.s.
I can't remember any more why, but you have my Witness vote :-)

Sort:  

Well shit ... that’s putting a damper on it ... didn’t know there were such differences within the language from one version to the next. Will have to check whats what. Thanks for the heads up.

ps. the witness vote might be because blockbrothers (our witness) makes Steemify. Regardless though, thanks for the vote 😊

Actually, happened only once, several years ago, Python got complete overhaul, they fixed many things from the past and in the process they broke backward version compatibility. Some companies are still running Python 2.7 (will be getting security updates up to 2020) because code they have is huge and it takes time to update it.

Example I gave you is, python 2.7 used print as statement and Python 3+ uses print as function, that's why it changed to print().

So, don't worry, there will not be this kind of radical changes going forward. But someone that is just starting with Python should definitely start learning Python +3. (latest current version is 3.6 with 3.7 just about getting ready) But any 3+ will do. Most Linux distros have preinstalled 3.5 while on Windows you just manually install latest one.

Thanks for the explanation. I think I’ll run this course just because I like how it’s set up. And then run another one (SoloLearn) thats on Python 3. It’ll help with confounding the code I learned while updating it to 3+

Coin Marketplace

STEEM 0.18
TRX 0.16
JST 0.031
BTC 60582.68
ETH 2607.66
USDT 1.00
SBD 2.55