The current ubantu18.04 has set python3 as the default compiler, and there is no pre-installed python2, but when I use the electron-ssr software, I need python2 interpreter, so I need to install python2.
According to this post:
https://linuxconfig.org/install-python-2-on-ubuntu-18-04-bionic-beaver-linux
sudo apt install python-minimal
You can install successfully
cd /usr/bin
ls -al|grep py
view version
python --version
or
python2 --version can be
in the case of
python3 --version is the pre-installed python3