On Wed, 18 Jul 2012 12:33:01 -0400, Dave Angel wrote:

> On 07/18/2012 08:58 AM, Steven D'Aprano wrote:

>> <SNIP>
>> For bonus points, can you see the mistake?
[...]
>>
> There are actually two bugs in that function.  One is in the assertion,
> but more importantly, there's a typo earlier.  One that would give a
> traceback, so it would be caught quickly.
> 
> UnboundLocalError: local variable 'x' referenced before assignment

Good catch :)



-- 
Steven
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to