Shell mode or editor

--Originally published at Codebuster

So you’ve got your idea and finally gather the wits to start to write your very first code, but… how?

Well, in python (and must other languages) you can choose from two alternatives, depending on what your goal is.

First we have the shell, to open the shell all you have to do is open the terminal you are working with, type “python3” (or the version you are using) on the command line:

opening shell.PNG

And you can immediately start writing code, but do keep in mind that the shell is in real time, best for quick calqulations or operations.

basic shell operation

However, if your aim is to write a longer code, or to use loops or such, you’re better off using a text editor, make sure to save the file with a .py

Then, just call it on the command line of your terminal and you are all set.