Can Python function return multiple data?

Steven D'Aprano steve at pearwood.info
Sun Jun 7 01:51:36 EDT 2015


On Sat, 6 Jun 2015 03:28 pm, Rustom Mody wrote:

> There was a list: [1,2,3]
> At some point that list is found to be(come) [1,2,3,4]
> They dont look same to me.

When you pour water into an empty bottle, does it turn into a different
bottle?

When you append items to a list (or remove them), it is still the same list.



-- 
Steven




More information about the Python-list mailing list