買這商品的人也買了...
-
$850Wireless Networking Technology: From Principles to Successful Implementation
-
$480$379 -
$147OpenCV 3 計算機視覺 : Python 語言實現, 2/e (Learning OpenCV 3 Computer Vision with Python, 2/e)
-
$1,590$1,511 -
$360$281 -
$3,150$2,993 -
$520$411 -
$245刷臉背後 : 人臉檢測人臉識別人臉檢索
-
$450$338 -
$352Kotlin程序開發入門精要
-
$505第一季Kotlin崛起:次世代Android開發
-
$403OpenCV 算法精解:基於 Python 與 C++
-
$266機器學習 : Python 實踐
-
$780$741 -
$2,288Network Defense and Countermeasures: Principles and Practices (3rd Edition) (Pearson IT Cybersecurity Curriculum (ITCC))
-
$301OpenCV Android 開發實戰
-
$750$675 -
$520$411 -
$1,200$948 -
$500$390 -
$620$527 -
$660$515 -
$750$593 -
$680$530 -
$680$537
相關主題
商品描述
本書通過大量實例,全面、系統、深入地講解了Python編程基礎及應用開發。主要包括: Python概述及開發環境、Python編程基礎、Python函數及模塊、面向對象編程、 Python界面設計、Python數據庫編程、Python網絡編程、Python網站開發、Python繪圖與圖像處理、Python科學計算。
作者簡介
石家莊鐵道大學信息學院教授,河北省中青年骨干教師,河北省計算機教學指導委員會委員,長期從事計算機基礎教學的研究,獲河北省教學成果獎4項(一等獎1項;二等獎3項);獲河北省科技進步獎2項。先後出版了多部教材
目錄大綱
第1章Python概述.............. 1
1.1 Python語言................ ..................1
1.1.1 Python的發展......................... ....... 1
1.1.2 Python的特點................................ 2
1.1.3 Python的應用領域........................ 2
1.1.4 Python的版本及安裝............. ....... 3
1.2 Python開發環境及工具..................5
1.2.1開發工具IDLE........... ..................... 5
1.2.2開發工具PyCharm ...................... .. 7
1.2.3編寫簡單的小程序.......................... 8
1.2.4 PyCharm配置....... .......................10
1.3習題........................ ....................11
第2章Python語言基礎...... 13
2.1 Python語言基礎............ ..............13
2.1.1 Python文件類型.......................... 13
2.1.2 Python編碼規範........... ............... 13
2.1.3輸入與輸出............................ ........ 15
2.2 Python數據類型..........................16
2.2.1 Number(數字)... ....................... 16
2.2.2 String(字符串).................. ....... 16
2.2.3變量及其賦值................................ 18
2.3運算符和表達式............................19
2.3.1算術運算符和表達式........ ............ 19
2.3.2賦值運算符和表達式....................20
2.3.3邏輯運算符和表達式.................... 21
2.3.4關係運算符和表達式.................. .. 22
2.3.5字符串運算符和表達式................ 22
2.3.6位運算符和表達式........... ............. 25
2.3.7運算符的優先級............................ 25
2.3.8 Python常用的函數...................... 26
2.4 Python數據結構................ ..........28
2.4.1列表................................... ..............29
2.4.2元組.............................. .....................32
2.3.3字典........................ .........................33
2.3.4集合.................... .............................34
2.5程序控制結構................ ...............36
2.5.1選擇結構............................. ............36
2.5.2循環結構................................ .........38
2.6編程實踐.................................... 41
2.7習題........................................... 44
第3章Python函數及模塊... 47
3.1案例引入及分析............................47
3.2函數........................................... 49
3.2.1函數的定義.................................... 49
3.2.2函數的調用..... ............................... 50
3.2.3函數的參數............ .........................51
3.2.4函數的嵌套................. ....................53
3.2.5函數的遞歸調用...................... ...... 54
3.3變量的作用域...............................54
3.4模塊.... ........................................55
3.4.1創建和導入模塊.. ...........................55
3.4.2模塊包................. ............................57
3.5編程實踐.................. .................. 58
3.6習題............................. .............. 61
第4章面向對象編程........... 63
4.1面向對象基礎............. ..................63
4.1.1面向過程與面向對象.....................63
4.1.2面向對象基本概念............. ........... 64
4.2類的定義和使用............................65
4.2.1類的定義.........................................65
4.2.2類的使用.........................................66
4.3類的屬性和方法. ...........................67
4.3.1類的屬性................ ........................ 67
4.3.2類的方法................... ..................... 69
4.3.3訪問控制....................... ................. 71
4.3.4構造函數和析構函數.................... 72
4.4類的繼承.....................................73
4.4.1類的簡單繼承... ............................. 73
4.4.2類的多重繼承............. ................... 76
4.5類的重載......................... ............77
4.5.1方法重載........................................ 77
4.5.2運算符重載.................................... 78
4.6編程實踐........ .............................80
4.7習題.................. ..........................85
第5章Python GUI編程..... 87
5.1 PyQt GUI工具包概述..... .............87
5.1.1 GUI簡介............................... ......... 87
5.1.2 PyQt工具包.................................. 88
5.1.3編程測試........................................90
5.2 PyQt GUI編程............................94
5.2.1信號和槽.............. .......................... 94
5.2.2主窗口QMainWindow................. 97
5.2.3對話框QDialog ............................. 98
5.2.4 PyQt輸入控件....... .....................101
5.2.5按鈕.............................................. 101
5.2.6顯示控件......................................103
5.2.7表格控件......................................104
5.2.8佈局控件...... ................................106
5.3編程實踐.............. .....................107
5.4習題.......................... ................110
第6章Python數據庫及文件系統.................114
6.1數據庫技術基礎... .......................114
6.1.1數據庫基本概念.................... ...... 114
6.1.2關係數據庫.................................. 115
6.1.3數據庫應用系統的開發步驟...... 116
6.2 MySQL數據庫..........................116
6.2.1數據庫安裝.. ................................ 117
6.2.2創建數據庫............ ...................... 121
6.2.3刪除數據庫.................................. 121
6.2.4 Mysql數據類型.... ...................... 122
6.2.5創建表...................... .................... 124
6.2.6編輯查看表....................... ........... 125
6.2.7刪除表................................. ......... 126
6.2.8插入數據................................... ... 126
6.2.9修改數據...................................... 126
6.2. 10刪除數據.................................... 127
6.2.11使用SELECT查詢數據... ....... 127
6.3 Python中訪問MySQL語句.......128
6.4 Python文件系統........................ 130
6.4.1文件的基礎知識.......................... 130
6.4.2文件的基本操作........ .................. 131
6.4.3文件的讀寫操作....................... ... 132
6.4.4文件與目錄操作函數和語句...... 133
6.5編程實踐:學生信息管理系統......135
6.6習題................ ..........................140
第7章Python網絡編程.....143
7.1網絡模型介紹....... ......................143
7.1.1 OSI簡介...................... ................. 143
7.1.2 TCP/IP簡介......................... ...... 144
7.2 Socket編程..............................147
7.2.1什麼是Socket... .......................... 147
7.2.2 Socket編程.................. ............... 147
7.2.3用Socket建立服務器端程序.... 148
7.2.4用Socket建立基於UDP的服務器與客戶端程序...... ............ 149
7.2.5用SocketSever建立服務器..... 150
7.3 urllib包與http包使用................. 151
7.3.1 urllib包........................................ 151
7.3.2使用httpIib包訪問網站............ 153
7.4使用ftplib訪問FTP服務............154
7.4.1 ftplib包..... ................................... 154
7.4.2使用ftplib包訪問FTP服務器..... ............................ 155
7.5電子郵件.................. .................156
7.5.1 SMTP和POP3.......................... . 156
7.5.2發送郵件...................................... 156
7.5.3接收郵件...................................... 158
7.6編程實踐....... ............................160
7.7習題................... .......................165
第8章Python網站開發.....167
8.1常見的Web開發框架........ .........167
8.1.1 Zope框架................................... .. 167
8.1.2 TurboGears框架....................... 167
8.1.3 Django框架................................. 168
8.2 MVC模式........ .........................169
8.2.1 MVC模式介紹.................. .......... 169
8.2.2 MVC模式的優缺點....................170
8.2.3 Django框架中的MVC.. .............170
8.3 Django開發環境的搭建..............171
8.3.1 Django框架的安裝........ ............. 171
8.3.2 Django簡單應用......................... 173
8.4 Django框架的應用....................176
8.4.1數據庫的配置...................... ........ 176
8.4.2創建數據模型.............................. 178
8.4.3創建視圖......................................180
8.4.4模板系統..... ................................. 182
8.4.5 URL配置........... .......................... 185
8.4.6發布Django項目........................ 185
8.5 Django框架的高級應用............. .186
8.5.1管理界面...................................... 186
8.5.2編輯數據庫.................................. 188
8.5.3 Session功能......... ....................... 189
8.5.4國際化..................... .....................190
8.6編程實踐......................... ..........193
8.7習題..................................... .....198
第9章Python數字圖像
處理...................... 200
9.1基本圖像操作和處理........ ...........200
9.1.1圖像和像素................................ ..200
9.1.2顏色空間...................................... 201
9.1.3像素的位深.................................. 202
9.2 Python圖像處理類庫PIL .... .......202
9.2.1 PIL模塊基本介紹....................... 203
9.2.2 Image模塊.............. .................... 203
9.2.3 PIL濾鏡效果...................... ......... 206
9.3 Python中使用OpenCV.............208
9.3.1 OpenCV安裝................ .............. 208
9.3.2 OpenCV基本操作...................... 209
9.3.3處理視頻序列.............................. 214
9.4 Matplotlib繪圖庫............... ........215
9.4.1 Matplotlib安裝........................... 215
9.4.2 Matplotlib模塊... ........................ 215
9.4.3 Matplotlib繪製簡單圖形........... 215
9.5編程實踐... ................................221
9.6習題............... ...........................223
第10章Python科學計算... 225
10.1 NumPy庫......... ......................225
10.1.1 ndarray對象............................ 225
10.1.2 ufunc運算........... ..................... 228
10.1.3矩陣運算....................... ............. 229
10.2 SciPy數值計算庫....................230
10.3編程實踐....... ..........................232
10.4習題..................... ...................233
參考文獻............................ 235