Macでは初めからPythonがインストールされていますが、2系なので、新たに3系をインストールしようと思います。
環境
Python 3.6.1
Homebrew 1.2.4
macOS Sierra 10.12.5
手順
Homebrewでインストールします。
ターミナルから以下のコマンドを実行します。
1 |
$ brew install python3 |
続いて「python3」と入力して「>>>」が表示されたら成功です!
1 2 3 4 5 |
$ python3 Python 3.6.1 (default, Apr 4 2017, 09:40:21) [GCC 4.2.1 Compatible Apple LLVM 8.1.0 (clang-802.0.38)] on darwin Type "help", "copyright", "credits" or "license" for more information. >>> |