Homebrew is a package manager for Mac OSX that allows easy management of Python and many other development tools. You must have Xcode installed before you install Homebrew. Then follow the instructions on the Homebrew homepage to install Homebrew.
$ brew update
$ brew install pythonOr
brew install python3for Python 3
$ brew linkapps
It seems that
brew linkappsis no longer supported.