Running python files on Putty


#1

I am trying to run a file on Putty using “sudo python Filename.py”
the file is also created on the nano editor of putty
but on using the sudo python Filename.py an erros shows up that “sudo: pyton: command not found”
any help??


#2

Hi @guneetbhatia.96 ,
It seems that you haven’t installed the python. First, install the python https://www.python.org/downloads/ .
Let me know in case you need further assistance.


#3

Hi, as show in your command error, there is a typing error. It’s supposed to be python and not pyton. Please check and let me know it this solves the issue for you.


#4

You can download the python installer from here for windows OS,


Download the required version for your use. Python 2.7.13 is widespread.

Linux systems come with python pre-installed. Else, you can run the following command,
sudo apt-get install python

Then verify if python is installed by running this command on the terminal,
python --version
It should display the version number of python.

Visit this link for more info,