3 ms·
Also I recently discovered that pypy supports non-ASCII characters pretty well which at least doesn't work with my version of python 2.7.6
by jegutman 11y ago
Also I recently discovered that pypy supports non-ASCII characters pretty well which at least doesn't work with my version of python 2.7.6
- ptx 11y agoIn what way?
- scardine 11y agoIn variable names, for example. You can do this: >>> π = 3.14 In Python 2: >>> π = 3.14 File "<stdin>", line 1 π = 3.14 ^ SyntaxError: invalid syntax
- auscompgeek 11y agoPython 2.7.10 (850edf14b2c7, Oct 29 2015, 17:32:05) [PyPy 4.0.0 with GCC 5.2.0] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>>> π = 3.14 File "<stdin>", line 1 π = 3.14 ^ SyntaxError: Unknown character Are you sure you weren't trying it in Python 3 (or PyPy3) rather than PyPy?
- takeda 11y agoI'm getting same result as scardine: Python 2.7.8 (default, Sep 30 2014, 15:34:38) [GCC] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> π = 3.14 File "<stdin>", line 1 π = 3.14 ^ SyntaxError: invalid syntax >>> also: Python 3.4.1 (default, May 23 2014, 17:48:28) [GCC] on linux Type "help", "copyright", "credits" or "license" for more information. >>> π = 3.14 >>> print(π) 3.14
- scardine 11y agoYou are right, this is Python 3 stuff. I just assumed the parent was talking about Pypy3.