Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I am new to Ubuntu and to programming, and I am seeking to teach myself Python. I installed the software from the Software Center and was wondering how to be sure it is up to date with the latest Python and where to go online for a guide that you would suggest, such as Non-Programmer's Tutorial for Python 3.

share|improve this question
    
I'd recommend learning with python 2. Python 3 is great, however most documentation is for 2.x –  Smithamax Dec 1 '11 at 9:53
3  
This question is not offtopic for this site. Don't close it! Python is one of the most important languages in Ubuntu, and if you look at the About page for AskUbuntu, you'll see the first line says: «This is a free, community driven Q&A for Ubuntu users and developers.» –  Jo-Erlend Schinstad Dec 1 '11 at 12:23
    
Helpful title, please! –  Oxwivi Dec 1 '11 at 13:12
    
Python 3 is well-documented too! Here it is: docs.python.org/py3k . Do read wiki.python.org/moin/Python2orPython3 –  Prateek Dec 1 '11 at 13:31
    
@Oxwivi Fixed now. –  WarriorIng64 Dec 1 '11 at 13:39
add comment

7 Answers 7

up vote 8 down vote accepted

You'll find a lot of information for non-programmers here.

share|improve this answer
add comment
  • Learn Python the Hard Way is a book by the wonderful Zed Shaw - he has been known to say (and others have said this as well) that once you've read/done the book, "you are a Developer, not a programmer", which can be nice. ;)

  • Python Beginners guide. - the official Python.org guide.

share|improve this answer
add comment

Welcome to the world of development on Ubuntu, John. Python is a wonderful programming language and is one of the absolute most popular ones in Ubuntu, which means there are many people who can help you get started and lots of good resources.

For direct help, I would recommend Ubuntu App Developer which is a website on http://developer.ubuntu.com, an active IRC channel on Freenode, called #ubuntu-app-devel and a mailinglist that you can join here: https://lists.ubuntu.com/mailman/listinfo/ubuntu-app-devel

Python.org in general is a very good resource, and you have many good references to free books, etc in the answer jcollado provided.

However, I would probably start with Python 2.7 is I were you. Though Python 3.x is available and is maturing nicely, a lot of third party libraries (programming tools) are still not upgraded and is therefore not available in Python 3.x yet. It is very easy to learn Python 3 when you've learned Python 2 first in any case, so your effort will not be wasted. Tools like Quickly and Quickly Widgets are not available for Python 3.x yet. They make it much easier and faster to get started developing real applications and publishing them as packages to be installed. You can read more about them on http://developer.ubuntu.com.

Have a lot of fun! :)

share|improve this answer
add comment

This free online book is pretty good, I was working through it myself.

share|improve this answer
add comment

Python is one of languages out there with Tons of resources. Here I will highlight few to start with. The best for beginners is the Official tutorial. Start there and once you are done you can have your books for in depth explanations. Some people starts with books and ends with tutorial but order is not that important. Some books are: Thinking Python A Byte of Python Dive Into Python Learn Python The Hard Way

Also if you have bandwidth check Bucky's youtube channel

share|improve this answer
add comment

I have always found the O'Reilly series a good place to look when starting to learn any programming language (whether it's your first, or your fiftith...).

Therefore I can whole heartedly recommend the 'Learning Python' book which I have used (and still use) to write my first opensource programme. It'll take you through non-language specific things like variables and modules, as well as introduce you to using python.

Personally, following from what Jo-Erlend Schinstad said, I would say start with Python 3. I my experience I've only found one library (GTK) which I needed that wasn't ported, and there are plenty of examples around now if you get stuck for code.

share|improve this answer
add comment

Many of the obvious locations of resources such as python.org have already been mentioned, but I would like to comment on a couple of others, and bring to light one that hasn't been mentioned before.

I have found that the freely available Think Python is an excellent introductory guide to both Python and programming in general. It has been updated for Python 3 here, and has been added to as recently as June 2012. The book has a lot of general points about programming as well which allow you to understand all the major concepts involved and the workflows that programmers construct. It contains chapters on the major aspects of Python and exercises to complete so that it helps you apply what you have learned.

I would also like to mention a site called codeacademy, which has recently began to offer some free interactive courses in Python as well as their other free courses on different programming languages. At the moment the tutorials are based on Python 2.7.3, although they will probably have some courses on Python 3 soon. They are still useful, however, for gaining some kind of introduction to Python.

A screenshot from the Python page is below and shows the initial exercises offered on the site and a lot more have been added recently; there are over 12 sections with hundreds of exercises ranging from functions to loops to input/output operations.

enter image description here

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.