On Wed, 21 Jan 2015 09:43:31 +0100, Peter Otten wrote:

> There is also dict.from_keys()

See, I learned something too.

> The inner loop is not just inefficient for stock sold in large
> quantities,

Agreed, but as for:

> it will fail for stock sold by weight, volume etc.

I was trying to stay true to OPs original code and not introduce [too 
many] additional complications to his learning exercise.

-- 
Denis McMahon, denismfmcma...@gmail.com
-- 
https://mail.python.org/mailman/listinfo/python-list

Reply via email to