On Thu, 27 Sep 2007 08:16:59 -0400, Steve Holden wrote: > Shriphani wrote: >> Hello, >> Would that mean that if I wanted to append all the (date, time) tuples >> to a list, I should do something like: >> >> for file in list_of_backup_files: >> some_list.append(file) > > That would be one way to do it (assuming you started with some_list as > an empty list). But a faster way would be to use a list comprehension > and say > > some_list = [f for f in list_of_backup_files]
Or: some_list = list(list_of_backup_files) If `some_list` is not empty: some_list.extend(list_of_backup_files) Ciao, Marc 'BlackJack' Rintsch -- http://mail.python.org/mailman/listinfo/python-list