一.IPython簡介
IPython 是一個(gè)交互式的shell,比默認(rèn)終端好用,支持自動縮進(jìn),并且內(nèi)置了很多有用的功能和函數(shù)。可以在任何操作系統(tǒng)上使用。
二.安裝方法
1.pip 在線安裝
pip install ipython
pip install “ipython[notebook]”
2.下載安裝
可以到GitHub 下載安裝包,切換到目錄下然后運(yùn)行下面的腳本
Python setup.py install
三.簡單使用
打開Linux終端,在命令行中輸入
root@Linux:/# ipython
便會進(jìn)入ipython 的交互式shell,并會顯示 ipython 的一些信息,在In [1]: 便可以輸入python的代碼
Python 2.7.6 (default, Jun 22 2015, 17:58:13) Type “copyright”, “credits” or “license” for more information. IPython 4.0.0 – An enhanced Interactive Python. ? -> Introduction and overview of IPython's features. %quickref -> Quick reference. help -> Python's own help system. object? -> Details about ‘object', use ‘object??' for extra details. In [1]: (此處輸入代碼)
比如打印”hello ipython”,輸入下列代碼
In [1]: print (‘hello ipython') hello ipython In [2]:
到此Linux環(huán)境安裝IPython配置python開發(fā)環(huán)境就弄好了,如果要在windows下配置開發(fā)環(huán)境,需要先安裝Anaconda,這是一種安裝管理的程序,使用它可以很方便的完成Python 的升級操作,并且自帶了很多的Python 庫。
以上就是本文的全部內(nèi)容,希望對大家的學(xué)習(xí)有所幫助。



















