>> Well the othe day I was making a program to make a list >> of all the songs in certian directorys but I got a problem, >> only one of the directorys was added to the list. >> Heres my code: >> >> import random >> import os >> import glob >> >> songs = glob.glob('C:\Documents and Settings\Admin\My >> Documents\LimeWire\Saved\*.mp3') >> >> asongs = glob.glob('C:\Documents and Settings\Admin\My
> From: [EMAIL PROTECTED] > To: "Cousin Stanley" <[EMAIL PROTECTED]>, > python-list@python.org > Date: Yesterday 07:28:18 pm > use songs.extend( asongs ) # append is for single item > # - where ever it might be. >>> l1 = range(5) >>> l2 = range(5,10) >>> l1 [0, 1, 2, 3, 4] >>> l2 [5, 6, 7, 8, 9] >>> l1.extend(l2) >>> l1 [0, 1, 2, 3, 4, 5, 6, 7, 8, 9] >>> And .... Thanks to Edwin Madari for reminding me about the extend method available for lists which I had totally forgotten about .... -- Stanley C. Kitching Human Being Phoenix, Arizona -- http://mail.python.org/mailman/listinfo/python-list