Python Notes #
Basics #
- Math Operators
- Common Data Types
- String Concatenation and Replication
- Variables
- Common Functions
- Text and Number Equivalence
Flow Control #
Elements of Flow Control #
Flow Control Statements #
Importing Modules #
Ending Programs Early #
Functions #
- Functions
- def Statement
- return Statement
- None value
- Keyword Arguments
- The Call Stack
- Local and Global Scope
- Exception Handling
Lists #
- List
- Index
- Slice
- len()
- List Concatenation and Replication
- del Statement
- in and not in Operators
- Multiple Assignment Trick
- enumerate()
- random Module
Augmented Assignment Operators #
Methods #
Sequence Data Types #
References #
Dictionaries and Structured Data #
Manipulating Strings #
- String Literals
- Escape Characters
- Raw Strings
- Multiline Strings
- Indexing and Slicing Strings
- in and not in String Operators
Inserting values in strings #
Useful String Methods #
- upper()
- lower()
- isupper()
- islower()
- isX() Methods
- startswith()
- endswith()
- join()
- split()
- partition()
- swapcase()
Justifying text #
Removing whitespace #
Unicode characters #
Copying and Pasting Strings #
Regex #
Input Validation #
Reading and Writing Files #
Files and File-paths #
File Reading and Writing #
Saving data #
Organizing Files #
Classes #
- Creating and Using a Class
- Class Inheritance
- Object Oriented Programming
- Importing Classes
- Styling Classes