Best way to uninstall; backup programs on Mac
To uninstall programs, just delete them. 

To back them up, the best idea is to keep the installer. In most cases, this is the .dmg the app came in. If it came from the App Store, there's nothing to keep. Other programs can come with installer packages (.pkg) or apps; these are what you'd keep in this case.