由於Python 中,變數不必聲明即可賦值,故Python 3 中引入關鍵字 nonlocal ,用 ... Rust 語言尤其不同,其允許在同一個代碼塊中多次宣告同名變數:後宣告者遮蔽先宣告者。
確定! 回上一頁