Eğitim Hakkında
The Introduction to Python for DevOps/Scripting training course is designed to demonstrate Python for scripting, automating, and enhancing productivity.
The course begins with an introduction to Python. Next, it explores basic programming skills to explain the necessity behind Python scripting. The course concludes by showing how to apply the knowledge from this training to solve future problems with Python.
Neler Öğreneceksiniz
- Create Python scripts to automate your daily work
- Know when Python is the appropriate solution and when it isn’t
- Understand the “nuts and bolts” of programming/scripting
- Apply that knowledge to solving new problems
Eğitim İçeriği
What is Python?
- Why use Python? (and when NOT to use it)
- Comparing Python to Bash and other scripting languages
Getting Started with Python–The Basics
- Variables/Typing
- Basic types
- Built-in Python Functions
- Python Arithmetic
- Code Blocks / Colons
- Control Structures
- if/elif/else
- Loops – for, while, range operator, the in operator
- Iterables / Sequences
- Slicing Operator
- Lists
- join()/split()
- sort() vs. sorted()
- enumerate()/ zip()
- Dictionaries, Sets, and Tuples
File I/O
- Reading and writing text files
- Parsing files
Functions
- Positional arguments
- Default arguments
- Keyword arguments
- *args/**kwargs
Modules
- What are they / how to use them
- import vs. from … import…
Useful Modules
- argparse: command-line parsing
- os, sys, subprocess: system management:
- shutil, tempfile, glob: file I/O and file management:
Regular Expressions
- Utilize regular expression syntax and Module (re)
- Search and replace
- Compile regular expression patterns
- Understand Regular expressions and input file parsing
Exception Handling in Python
- What is an exception?
- LBYL vs. EAFP styles of programming
- try/except, else, finally