I decided this would be the best way to document what I am currently learning about python. Feel free to add your knowledge, as I am an absoulte beginner.

Hello world in python

#! /usr/bin/env python
print "Hello World"

To call it, just type the name of your script.

File handling

Helped me a lot:
http://www.sourcesnippets.com/python-file-handling-with-python.html

Loops

The for loop
for i in range(1, 5):
   print i
else:
   print 'The for loop is over'

-- SarahHeim - 13 Feb 2009
Topic revision: r3 - 16 Oct 2009, TomRockwell
 

This site is powered by FoswikiCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding Foswiki? Send feedback