Python logo

目錄

  • 內建型別
    • 真值檢測
    • Boolean(布林)運算 --- and, or, not
    • 比較運算
    • 數值型別 --- int、float、complex
      • 整數型別的位元運算
      • 整數型別的附加方法
      • 浮點數的附加方法
      • 複數的附加方法
      • 數值型別的雜湊
    • Boolean 型別 - bool
    • 疊代器型別
      • Generator Types
    • Sequence Types --- list, tuple, range
      • Common Sequence Operations
      • 不可變序列型別
      • 可變序列型別
      • List(串列)
      • Tuple(元組)
      • Ranges
    • Text and Binary Sequence Type Methods Summary
    • Text Sequence Type --- str
      • 字串方法
      • Formatted String Literals (f-strings)
        • Debug specifier
        • Conversion specifier
        • Format specifier
      • 模板字串字面值 (t-strings)
      • printf-style String Formatting
    • Binary Sequence Types --- bytes, bytearray, memoryview
      • Bytes Objects
      • Bytearray 物件
      • Bytes 和 Bytearray 的操作
      • printf-style Bytes Formatting
      • Memory Views
    • Set Types --- set, frozenset
    • Mapping Types --- dict
      • 字典視圖物件
    • 情境管理器型別
    • 型別註釋的型別 --- 泛型別名 (Generic Alias)、聯合 (Union)
      • 泛型別名型別
        • 標準泛型類別
        • GenericAlias 物件的特殊屬性
      • 聯合型別 (Union Type)
    • 其他內建型別