sys is a built-in module, but it's not in the namespace unless you import it first. before your print statement, enter "import sys"
On Fri, Jun 17, 2022 at 8:23 AM <z.szende...@hotmail.com> wrote: > Thank you for your email. > > C:\Users\zszen>python.exe > Python 3.10.5 (tags/v3.10.5:f377153, Jun 6 2022, 16:14:13) [MSC v.1929 64 > bit (AMD64)] on win32 > Type "help", "copyright", "credits" or "license" for more information. > >>> print(sys.version) > Traceback (most recent call last): > File "<stdin>", line 1, in <module> > NameError: name 'sys' is not defined > > >>> print(sys.executable) > Traceback (most recent call last): > File "<stdin>", line 1, in <module> > NameError: name 'sys' is not defined > > On Fri, Jun 17, 2022, at 12:35 PM, Eryk Sun wrote: > > On 6/17/22, Zoltan Szenderak <z.szende...@hotmail.com> wrote: > > > > > > print(sys.version_info) and executable: > > > Unable to initialize device PRN > > > > That's the command-line "print" program. You need to first start the > > Python shell via python.exe. The prompt should change to ">>> ". Then > > run print(sys.version) and print(sys.executable). > > > -- > https://mail.python.org/mailman/listinfo/python-list > -- https://mail.python.org/mailman/listinfo/python-list