#學習目標:用Python程式語言實現從輸入到輸出的演算法
了解Python程式碼的組成
會使用各種資料類型來承接輸入資料
運用各種運算子組合成表示式,以進行計算
控制帶有決策與迴圈的流程
輸出運算結果的正確格式
2021/09/12
基礎程式設計(一)-EE300044¶
Fundamental Computer Programming(1)

第1週(9/13)-程式語言和IPO-model¶
W1 Essential-基本的¶
啟思博的概念(Kissipo Learning)
KISS Principle: Colab + Github的使用
IPO model: input–process–output (輸入-處理-輸出) input()和print()
Anaconda 和Jupyter notebook
Hello World程式
W1 Advanced-進階的¶
關於Python 程式語言
不同Python編輯器的介紹:IDLE, Spyder, Visual Studio Code, PyCharm
Python程式的執行 (Run)
Python程式的偵錯 (Debug)
第2週(9/20) 彈性放假¶

第3週(9/27)-Python的變數和運算¶
W3 Essential-基本的¶
Input: input()函數的使用和參數(prompt), 變數和資料型別(int, str), type()
Process: 指定敘述(assignment),表示式(expressions ), 算術運算子和運算優先順序, 標準庫math的應用
Output: print()函數的使用和參數(sep, end),Escape Sequence (逸出序列)
W3 Advanced-進階的¶
多行的字串
程式註解
MarkDown語法
第4週(10/4)-Python簡單流程控制¶
W4 Essential-基本的¶
Input: 序列(List), 字串切割(str.split()), len()函數,
Process: for-loop, 多重指定敘述(multiple assignment), 型別轉換函數(int(), str(), float()),索引(Indexing)和切片(Slicing)
Output: f-格式化字串, print()的格式化輸出
W4 Advanced-進階的¶
舊式字串格式化 (1) 百分比符號字串格式化(% string formatting) (2) str.format() 函數
序列(List)的初始化和插入append()函數
https://realpython.com/lessons/old-school-string-formatting-python/
第5週(10/11) 彈性放假¶

第6週(10/18)-條件式(condition)和資料容器(Container)¶
W6 Essential-基本的¶
Input: map()函數的使用
Process: if條件式, 比較運算子, 布林值和布林邏輯, while迴圈
Output: 字串的format(), zfill(), center(), rjust()和ljust() 函數
W6 Advanced-進階的¶
List, Tuple, Dict, Set資料容器(Container)
內建函式—max()、min()、sum()
第7週(10/25)-常用內建函數以及字串的使用¶
W7 Essential-基本的¶
Input: input的複習
Process: 字串函數, ascii函數, unicode函數,字串的索引(Indexing)和切片(Slicing)
Output: Output的複習
W7 Advanced-進階的¶
內建函數:pow()、divmod()、round()
內建函數:repr()和eval()
第8週(11/1)-M1Test模組一測驗¶
基礎程式設計(二)-EE300045¶
Fundamental Computer Programming(2)

第9週(11/8)-檔案處理(1):I/O函數¶
W9 Essential-基本的¶
Input: I/O函數(open() and read()), with/as的使用
Process: 資料排序, sorted()函數, max()/min()函數
Output: I/O函數(open() and write())
W9 Advanced-進階的¶
os, glob, pathlib模組-Python Standard Library
第10週(11/15)-檔案處理(2):json 結構化¶
W10 Essential-基本的¶
Input: 讀入 json 結構化資料
Process: for-loop/while-loop, range()函數, enumerate()函數
Output: 使用 json 儲存結構化資料
W10 Advanced-進階的¶
Zipping and unzipping lists and iterables
迭代器工具(itertools)-Python Standard Library
Sliding windows (n-grams) using zip and iterators
time.sleep() : 讓程式暫停幾秒鐘(需先匯入time模組)
第11週(11/22)-例外處理 (Exception)¶
W11 Essential-基本的¶
Input: 字典(dictionary)
Process: 流程控制:
Output:
W11 Advanced-進階的¶
使用lambda函數
Inverting a dictionary using zip
生成式(Comprehension)
eval()和exec()函數
並行、平行與非同步
第12週(11/29)-生成器(Generator)¶
W12 Essential-基本的¶
Input: 集合(set)
Process: 迴圈控制Loop controls(break, continue pass ), 例外處理 (Exception)
Output:
W12 Advanced-進階的¶
Loop with zip
例外處理 (Exception)
第13週(12/6)-M2Test模組二測驗¶
基礎程式設計(三)-EE300046¶
Fundamental Computer Programming(3)

第14週(12/13)-函數(1)定義、呼叫和傳回值¶
W14 Essential-基本的¶
函數的定義、呼叫和傳回值, function definition and call
參數預設資料
參數名稱對應
全域與區域變數
W14 Advanced-進階的¶
亂數(random)-Python Standard Library
第15週(12/20)-函數(2):遞迴函數,預設參數, 多重傳回值¶
W15 Essential-基本的¶
遞迴函數 (Recursion),
函數的預設參數
函數的多重傳回值
函數的呼叫
呼叫任意長度參數(函數呼叫的*t參數型式)
呼叫任意長度參數(函數呼叫的**t參數型式)
任意長度的參數(函數定義的*t參數型式)
W15 Advanced-進階的¶
日誌(logging)-Python Standard Library
第16週(12/27)-類別(Class)¶
W16 Essential-基本的¶
類別(Class)
裝飾詞(Decorator)
W16 Advanced-進階的¶
正規表示式(Regular Expression)-Python Standard Library
第17週(1/3)-模組(Module)¶
W17 Essential-基本的¶
模組(Module)
W17 Advanced-進階的¶
時間(Time)-Python Standard Library
日期(Datetime)-Python Standard Library
日曆(calendar)-Python Standard Library