Set Comprehensions Don't Work On Pydev (python)
{x for x in range(10)} works perfectly on IDLE, but when I try this in eclipse (with Pydev plugin) I get a syntax error: Undefined variable: x Is it because Pydev doesn't suppor
Solution 1:
This is a bug in PyDev; in this case ignore the editor's warning and execute the code: it will work.
I get this a lot, PyDev isn't perfect but it's good enough!
Solution 2:
Solution 3:
You can find out which version of Python you are using with
import sys
sys.stdout.write( sys.version )
Post a Comment for "Set Comprehensions Don't Work On Pydev (python)"