I installed Mathematica 10 long ago on my GNU/Linux Debian. Now I want to install Mathematica 11.0.1. The directory that I installed Mathematica 10 is /home/programfiles/mathematica/10. That is to say, when installed 10, I have changed the default directory to my home directory. I have searched the uninstall scripts, but there is no such a script-file in the installation directory. So, is it right to delete the whole /home/programfiles/mathematica/10? Or how can I uninstall Mathematica 10?
You can get the uninstall instructions here. It is mentioned that you need to delete the install directory and two other directories.
You could just delete the directory that you have installed Mathematica in, which is /home/programfiles/mathematica/10. I'd also suggest you remove the symbolic links after you remove the directory.
should tell you the location of the symbolic links. There are usually five or six symbolic links created when mathematica is installed. Some of them are math, mathematica, MathKernel, etc. Go ahead and delete all the symbolic links relevant to Mathematica.
If you are installing a newer version, I think these links should be replaced. However, I'd suggest it is better you clean it up before installing a newer version of Mathematica.