wilfredinni/python-cheatsheet

Chestsheet -> Functions -> Lambda Function - error in third example (lexical closures)

m-zurowski opened this issue · 4 comments

image

I wasn't sure why this code is written in such way, so I tried it on my pc and it doesn't work - the x is taken out of the blue :)

(I'm just learning, so I might be wrong)

https://www.pythoncheatsheet.org/cheatsheet/functions

hey! it works fine:

image

Hey Guys,

Thanks for helping me understand it - looks like my brain had an issue with this one ;)

Screenshot was taken directly from pythoncheatsheet page.

Problem was between the monitor and the chair, marking as resolved.