Sage-Code Laboratory

Python Tutorial

Python is a high-level dynamic computer language. At this time it is the second most popular computer language. Python was written by Guido van Rossum as a system scripting language. Some universities are using Python to teach programming concepts for Computer Science course.

Video Lecture

Next video lecture is 15 minutes long. It was made in Chicago in 2016. If you do not have the bandwith for videos, or if you already know about Python you can skip it. But if you watch it, you can post a comment and click the like button. This will help others intrested in programming to find it and learn about us.

Python Language

Course Scope

This tutorial is for very beginners. It is a fast pace essential tutorial based on simplified English. We have presented the language features in logical order with short examples and notes. You should scroll down and read without pause or intreruptions until you finish each page. At the end of every page you should take a breack. One page/day will enable you to finish the course in about 8 days. We recommand to learn 4 days/week so in two weeks you will become a Python developer.


This tutorial is organized like a book. At the end of each page there is a link for the next page. Every page has a index link on top right corner, that will bring you back here. If you wish to go back to a previous chapter, use the browser back button or the index below. If you are first time here, skip the index and read on. You will use the index later.


  1. syntax
  2. variables
  3. control flow
  4. functions
  5. classes
  6. generators
  7. closures
  8. packages

Python Issues:

Python is a great language if you use it for the right application. It is a productive language, but you should be aware of several limitations before chosing Python for your next project.

Why is Python slow?

Python has several principles that are called "Zen of Python". Python is slow because of these principles. It was designed to be "user friendly" that is why is a "dynamic typed language" and not a "static typed language."

And what it means. During runtime you can change value and value type for a variable by using an assign statement. Another problem Python has is the GIL (global interpreter lock) this is hard to explain but it makes multicore/parallel applications work slow.

But… it also depend on algorithms you are using. How much data you store in memory and how this data is organized. Python do not have Arrays like C, C++ and Java. Array require fix data length. In Python a collection can hold any kind of data: Numeric, String even other collection. So you can have a list of lists or a dictionary of lists. This is why Python is slow.

Tools & Resources

A project require practice. Professional developers work locally on desktop computers and laptops. You can setup Pithon interpreter on your computer. Also there is a nice IDE available called IDLE. To make advanced projects in Python I recommand PyCharm IDE editor that has a community edition.

Running Examples

You do not need to install Python to follow this tutorial.For quick learning you can use website.I have posted some of our examples on my account for you to review and test. You will find links to so called "homeworks" that enable you to open these examples on-line. You can log-in with your GitHub account but this is not necesary for opening the examples, just if you wish to create your own.

Responsive Immage

On-line Example

Python I - Prep Quiz

Next quiz has only 60 questions, each question value one point. It is special designed for a mobil device. You can click, tap or scan the image below to start. This quiz does not have time limit, but it requires you to sign-in using your Google account. Break a leg!
Python Quiz

Python Quiz

Privacy Terms: We do not collect your e-mail address but we record your name with the test results on Google drive. If you take more than 80% we will recognize your skill and will endorse you on Linked-in. If you don't agree, you can use name: Anonymous but then we can't endorse your new skills.

Before taking this quiz, you should learn some Python. We organize this tutorial like a book so you can turn page by pressing the link below. Before you do, we advice you to take a break here and streatch your legs. Very important!

Start Here: Syntax Overview