2018-11-04 【Python 2.7】Pythonの実行方法2つ Python Pythonを実行する方法は2つある。 コマンドラインから実行 $ python >>> print "hello world" hello world >>> exit() $ コマンドラインで実行するには、pythonと実行すればいい。 終了はexit()、もしくはctrl+D ファイルとして保存して実行 vimで編集 $ vim hello.pyhello.py print "hello world" 実行 $ python hello.py hello world $