This is a collection of Jupyter Notebooks for teaching Python programming with an emphasis on the fundamentals of Cyber Operations. It's not meant to be a complete Python textbook, but rather an organized reference guide to allow you to see interactive examples on specific Python topics.
Python 3.8.x is currently shipping with Ubuntu 20.04.x.
- Introduction
- Using Jupyter Notebooks
- Your first Python program
- Basic operations
- Variables, assignment statements, expressions
- Reading console input
- Numeric data types
- Operator precedence
- Strings
- Type conversions
- Formatted String Literals (f-strings)
- Built-in Functions and Objects
- Common functions
- Objects and methods
- Branch Logic
- Boolean data types
if
statementsif
-else
statementsif
-elif
-else
statements- Logical operators (
and
,or
,not
) - Operator precedence
- Iteration (Loops)
for
loopwhile
loop- Nested loops
break
andcontinue
- User Defined Functions
- Introduction
- Defining functions
- Calling functions
- Arguments and parameters
- Variable scope
- Collections: Lists, Dictionaries, Sets, Tuples
- Creating
- Accessing data
- Functions - returning multiple values
- Functions - pass by value; pass by reference
- File I/O
- Modes: read (
'r'
), write ('w'
), append('a'
) - Writing and closing:
write()
,close()
- Ways to read:
read()
,readline()
,readlines()
- Modes: read (
- Hashing
- Hashing strings
- Hashing strings
- Exception Handling
- Catching exceptions
- Raising exceptions
- Recursion
- Introduction
- Examples
- OOP
- User defined classes
- User defined classes
- Misc Topics