Building lists

Ian Kelly ian.g.kelly at gmail.com
Mon Oct 20 15:58:46 EDT 2014


On Mon, Oct 20, 2014 at 1:49 PM, Seymore4Head
<Seymore4Head at hotmail.invalid> wrote:
> For starters I would like to know if you can make a single item list
> and then turn it into a 2 item list.  Is there a command for that?

You mean like this?

>>> the_list = ['first_item']
>>> the_list.append('second_item')
>>> the_list
['first_item', 'second_item']



More information about the Python-list mailing list