Programming

Do you ever find yourself doing some small, repetitive task on a computer? You are a perfect person to learn to program a computer! Programming a computer is a daunting idea to many. Put that out of your mind. Not long ago just using a computer was a daunting idea. Times change. We learn. We grow.

It helps to pick a language to express your repetitive task in. Python is free and open source and accessible to new programmers. Many computers already have Python installed. If yours does not, you can download it here:

http://www.python.org/download/

As they mention there, starting with the 2.x version is currently still recommended as things transition to 3.x (*2010.12.09 11:35:07).

One good place to start learning about Python is: http://diveintopython.org/ Dive Into Python http://diveintopython.org/toc/index.html Dive Into Python

Other good sources are: http://www.greenteapress.com/thinkpython/thinkpython.html http://openbookproject.net//thinkCSpy/ How to Think Like a Computer Scientist — How to Think Like a Computer Scientist: Learning with Python v2nd Edition documentation

[via learning]

Two of the most useful concepts in programming are Loops and Conditions.

Loops:

do something again and again. in python:

while True:
print "Hello"

writes "Hello" forever (or until ctl-C is pressed)

Conditions:

if a == 1:
print "A is equal to 1"
elif a == 2:
print "A is equal to 2"
else:
print "A is many"

describe what to do in all of the different variations that come up in your task.

More info:

I have many more topics about using python in: Python

and more generally: All tags