# list # A list is an ordered set of items, separated by comma in square brackets. # Items can be of any type (stings, integers, ...) mylist = ["Symbian", "PyS60", "MobileArt"] print mylist # accessing an item of a list myitem = mylist[2] # reads out the 3rd item "MobileArt" (3rd item has list index 2) print myitem # adding an item at the end of the list mylist.append("Fun") # the list looks now like ["Symbian", "PyS60", "MobileArt", "Fun"] print mylist # removing a certain item from a list mylist.remove("MobileArt") # the list looks now like ["Symbian", "PyS60", "Fun"] print mylist # removing an item at a position of a list mylist.pop(1) # the list looks now like ["Symbian", "Fun"] (2nd item "PyS60" had list index 1) print mylist # replace an item of a list mylist[1] = "Python" # the list looks now like ["Symbian", "Python"] (we changed the 2nd item "Fun" that had the list index 1 to "Python") print mylist