Find and Remove Package on Ubuntu Linux

I recently installed a couple packages that I didn’t need any longer on an Ubuntu Linux system. Most likely, you’ve installed packages using apt install or apt-get install. However, neither of these commands offer a command that lists out the packages that you’ve installed. To list out the installed packages, you use the dpkg command instead.

For example, let’s say you wanted to remove Python3.5. You could use dpkg –list python* to find all of the packages that start with the text “python.” Then you’d use the sudo dpkg –remove python3.5 command or sudo apt remove python3.5 command to actually remove the package.