Topic: Installing Python & writing your first script

Code prompt: print("Hello, Jake! Welcome to Python.")

Details: Learn how to install Python and write your first print statement.

Log:

Starting off, I’ve already got python installed, which can be checked easily in the terminal using:

python —version OR python3 —version #(note two dashes being used here)

This returns the version number, and therein confirms that python is present:

image.png

If python isn’t present, there a tons of ways to install it (a quick google will show you that) - but I’d recommend downloading Anaconda, which is a free toolbox that contains python3 as well as Jupyter and a bunch of other useful stuff. It will also help manage a lot of issues beginners can encounter when installing python for the first time!

Printing a command:

With python installed, we can attempt the rest of our day1 task: running a simple command to make sure things are working as intended. I’m going to launch an editor called ‘Mu’, which is super simple (and also free), to use the terminal window there for now.

We’re going to start with a twist on the print command used in nearly every tutorial ever: “hello world”. In this case, lets say hello to python:

image.png

Using print statements is super simple. You’ll start by evoking the print statement, and then tell python what you’d like it to print to the terminal (’inside quotes and brackets, like this!’). Then, simply hit enter to print your line of code!

With that, day one’s tasks are done. Happy printing!