- Notifications
You must be signed in to change notification settings - Fork619
A Python 3 programming tutorial for beginners.
License
Akuli/python-tutorial
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
This is a Python 3 programming tutorial for beginners. If you have neverprogrammed before clickhere to findout what programming is like and get started.
This tutorial is aimed at people with no programming experience at allor very little programming experience. If you have programmed a lot inthe past using some other language you may want to readthe officialtutorial instead.
You can use Python 3.2 or any newer Python with this tutorial. Don't usePython 2. If you write a Python 2 program now someone will need to portit to Python 3 later, so it's best to just write Python 3 to begin with.Python 3 code will work just fine in Python 4, so you don't need toworry about that.
The tutorial consists of two sections:
This section will get you started with using Python and you'll be ableto learn more about whatever you want after studying it.
- What is programming?
- Installing Python
- Getting started with Python
- ThinkPython: The way of the program
- Variables, Booleans and None
- Using functions
- If, else and elif
- Handy stuff with strings
- Lists and tuples
- Loops
- Trey Hunner: zip and enumerate
- Dictionaries
- Defining functions
- Writing a larger program
- What is true?
- Files
- Exceptions
- Modules
- Classes
If you want to learn more advanced techniques, you can also read thissection. Most of the techniques explained here are great when you'reworking on a large project, and your code would be really repetitivewithout these things.
You can experient with these things freely, but pleasedon't use thesetechniques just because you know how to use them. Prefer the simpletechniques from the Basics part instead when possible. Simple is betterthan complex.
- Important:getting help
- Contact me
- Setting up a text editor
- Answers for excercises inbasics andadvanced sections
- The TODO list
You can star this tutorial. Starring is free for you, but it tells meand other people that you like this tutorial.
Gohere if you aren't herealready and click the "Star" button in the top right corner. You will beasked to create a GitHub account if you don't already have one.
Currently (Feb. 2017) this tutorial is updated often, so it's best toread this tutorial on GitHub to make sure you are reading the latestversion. But you can also download this tutorial and read it withoutInternet if you need to, like this:
Gohere if you aren'there already.
Click the big green "Clone or download" button in the top right ofthe page, then click "Download ZIP".
Open the ZIP, then drag and drop
python-tutorial-master
to yourdesktop.Install Python and open a command prompt orterminal. If you are using Windows,run these commands:
cd Desktoppython-tutorial-masterpy make-html.py
Use these commands instead on Linux and Mac OSX:
cd Desktopcd python-tutorial-masterpython3 make-html.py
Follow the instructions you see on the terminal or command prompt.
If you have git and you know how to use it, you can also clone therepository instead of downloading a zip and extracting it. An advantagewith doing it this way is that you don't need to download the wholetutorial again to get the latest version of it, all you need to do is topull with git and runmake-html.py
again.
I'm Akuli and I have written most of this tutorial, but these peoplehave helped me with it:
- SpiritualForest: Lots of typingerror fixes.
- theelous3: Small improvements and fixes.
TODO: add the names of all beginners who have told me what they struggled with.
If you have trouble with this tutorial pleasetell me aboutit and I'll make this tutorial better. If youlike this tutorial, pleasegive it astar.
You may use this tutorial freely at your own risk. SeeLICENSE.
About
A Python 3 programming tutorial for beginners.
Topics
Resources
License
Uh oh!
There was an error while loading.Please reload this page.
Stars
Watchers
Forks
Releases
Packages0
Uh oh!
There was an error while loading.Please reload this page.
Contributors11
Uh oh!
There was an error while loading.Please reload this page.