Python Basics - PYTHON01 Course Outline

(5 Days)


Python is an interpreted, object-oriented, high-level language that empowers you to automate your work so it can be completed predictably and accurately. This freely available language is installed on all major platforms without a charge. Given Python’s vast libraries, you’ll have a head start programming most tasks.


Be it system admins, network, cloud, or storage engineers, all lessons in our courseware are highly relevant for scripting within the workplace, including; data retrieval and storage from the local system, working with RESTful APIs, and decoding JSON.

Audience Profile

     This course is an appropriate introduction to students of any background looking to get started with Python

     System Administrators

     Network Administrators and Engineers

     DevOps Engineers

     Management, Directors, VPs


Keyboard proficiency

At Course Completion

     Current Python3 Standard Library

     Popular 3rd party libraries

     Version control with git

     Git integration with popular SCM (GitHub)

     Parsing and building files

     Pull JSON from API queries

     Manipulate Excel and other popular formats with pandas dataframes

     Building feature rich charts and graphs

     Searching with Regular Expressions (regex)

     Best practice techniques

Course Outline


  1. Introduction to Python

     Installing Python 3.x

     Preparing to write Python

     Preparing to write a Python file (*.py) – Text Editors

     Executing a Python file

     Python Enhancement Proposals (PEPs)

     Python Statements and Control Flow

     Python Interpreter

     Overview of the Standard Library


  1. Version Controlling Code with Git

     Overview of Git

     Git commands

     Set up a GitHub account

     GitHub essentials

     README course requirements

     How to Set up a repo

     Issue a Pull request

     How to use “Issues” for peer review


  1. Basics of Programming

     Functions and purpose of main()



     Built in Functions


     Controlling standard out

     White spacing basic rules

     String Literal Escape Sequences

     Python Variables

     Naming Conventions & Rules

     Types as Objects

     Sequence Types

     List Iteration

     List Enumeration

     Sequence Assignments

     Mutable vs Immutable Objects

     Assignment Shorthand


  1. Python Basic Variables and Data Types

     Numeric Types

     Operators and Precedence / Arithmetic Expressions


     Floating points



  1. String Types

     Generating Strings in Python

     Common String Methods

     Formatting String Output


     Printing and formatting strings

     Scripting with input()

     About raw_input()


  1. Lists & Dictionaries & Tuples


     Mixed Lists

     Common List Methods

     Other List Operations

     An overview on and construction of dictionaries

     Keys and Values

     Dictionary Methods


     Python Time Tuples

     Dictionaries vs Lists vs Tuples

     Translating JSON to Pythonic data


  1. If, elif, else

     Relational Operators

     Logical operators

     Comparison Operations

     “simple” if Statement

     If else statements

     If elif

     Nested if statement


  1. Looping with “while”

     While usage

     Count controlled loop

     Event controlled loop




  1. Looping with “for”

     The for Loop

     For iteration examples

     Looping across data sets

     Looping across lists of lists

     Looping across lists of dictionaries


  1. Understanding Iterators

     The range() Function

     Taking the range() of len()

     Iterable Objects

     The iter() Function

     Looping with dictionaries

     Looping with lists


  1. Getting Data In and Out of Python

     Opening Files

     Working with Files

     Read data from files

     Controlling Output Location

     Intro to working with APIs

     What is a “REST”ful API?

     APIs and JSON


  1. Creating Python Functions

     Function Basics

     Defining Functions

     Function Polymorphism

     Argument Defaults


     What is if __name__ == “__main__”

     Local Variables

     Variable Masking

     Preventing Variable Modifications

     Argument Matching Methods

     Basic List Comprehensions


  1. Modules & Packages

     Pip and pip3

     Module Basics


     Virtual environments

     Defined modules

     Import modules

     From import statements

     Some useful modules to know

     RESTful APIs and requests

     Dataframes with pandas

     Graphing with matplotlib


  1. Python Scope

     Naming conventions

     Local scope

     Global scope

     Nested scope


  1. Object Oriented Python

     About OOP

     The Class Statements

     Defining a class

     Class Inheritance

     Classes as Objects

     Using Dictionaries

     Understanding self

     Class fields and constructors

     Data structures

     Subclasses (Inheritance)

     Multiple Inheritance

     Static methods


  1. (Optional) Regular Expression

     import re library

     Writing regular expression

     Searching for data in files

     Using Regular Expression to search data sets

     Searching for data in Wireshark Traces (Python and *.pcaps)



     Lab 1.  Welcome to Alta3 Research Labs

     Lab 2.  Using vim

     Lab 3.  Python IDEs

     Lab 4.  git and GitHub

     Lab 5.  Install Python

     Lab 6.  Shebang

     Lab 7.  Print

     Lab 8.  Getting user input()

     Lab 9.  Working with Lists

     Lab 10. List Objects and Methods

     Lab 11. Lists of Lists

     Lab 12. Python Dictionaries

     Lab 13. Getting dir(obj) help() and pydoc

     Lab 14. String Methods

     Lab 15. Copying Files and Folders

     Lab 16. Moving and Renaming Files and Folders

     Lab 17. Testing with if

     Lab 18. IPv4 Testing with if

     Lab 19. Writing your own if-logic script

     Lab 20. Using while, if, elif, else

     Lab 21. Troubleshooting while, if, elif, else

     Lab 22. Starting to Learn Loops

     Lab 23. Looping with for

     Lab 24. for loops and range()

     Lab 25. Migrating 2.x to 3.x py

     Lab 26. Parsing Log Files

     Lab 27. Write to Files

     Lab 28. Read from Files

     Lab 29. Archive with zipfile

     Lab 30. Creating Functions

     Lab 31. pip and import

     Lab 32. Exploring Network Interfaces

     Lab 33. Defining Functions

     Lab 34. Scripting Commands with Python

     Lab 35. Producing Graphs and Charts

     Lab 36. Walking the Directory Tree

     Lab 37. Excel and Intro to Pandas

     Lab 38. RESTful APIs and JSON

     Lab 39. Searching with Regular Expressions

     Lab 40. Use RegEx to Search Text

     Lab 41. Best Practice and pylint

     Lab 42. Testing with pytest

     Lab 43. Packaging Python Projects

     Lab 44. Running Python Scripts with Crontab

     Lab 45. Creating objects in Python from “Scratch”

     Lab 46. Class Inheritance

     Lab 47. Using Classes

     Lab 48. Argument Parsing

     Lab 49. Unpacking Arguments

     Lab 50. Automating SMTP and Extended SMTP

     Lab 51. XML Parsing with ElementTree

     Lab 52. Timestamping – import time datetime