icon icon

Python Advanced – functions, OOP and code quality

icon

Training process

Training needs analysis

If you have specific requirements regarding the training programme, we will carry out a training needs analysis for you. This will guide us on which aspects of the programme should receive greater emphasis, so that the training programme meets your specific needs.

What will you gain?

icon

Confident function design - You will learn how to choose positional, named, *args and **kwargs parameters deliberately, so you can build clearer function APIs and write code that is easier to extend.

icon

Smarter use of generators - You will start using generators and yield when handling large datasets, helping you reduce memory usage and create more efficient scripts for real data processing tasks.

icon

Automation with decorators - You will write your own decorators for logging, validation and caching, so you can add recurring behaviors to your code faster without copying the same logic again and again.

icon

Stronger practical OOP - You will organize your work with classes, inheritance, composition and properties, making it easier to design objects that stay readable, maintainable and convenient to use.

icon

Efficient file handling - You will learn to safely read and write text, CSV and JSON files, handle exceptions and manage paths, which will help you with many everyday automation and scripting tasks.

icon

Reliable date and time work - You will work more confidently with dates, times, formatting and basic time zones, helping you avoid common mistakes in logs, reports, schedules and time-based workflows.

icon

Better application diagnostics - You will configure Python logging and match log levels to real situations, so you can trace program behavior, spot issues faster and keep diagnostic messages well organized.

icon

Higher code quality with tests - You will learn unittest or pytest, write unit tests and use mocks, so you can verify changes faster and develop existing code with more confidence and less risk of regressions.

Training programme

1. Functions – intermediate elements

  • positional and keyword arguments,
  • *args and **kwargs,
  • anonymous functions (lambda),
  • functions as objects (passing functions),
  • variable scope (LEGB),
  • nested functions and closures.

2. Generators

  • iterators vs generators,
  • the yield keyword,
  • generators as an alternative to lists,
  • generator expressions,
  • processing large data sets.

3. Decorators

  • what decorators are and how they work,
  • creating your own decorators,
  • decorators with arguments,
  • applications (logging, validation, cache),
  • combining multiple decorators.

4. Object-oriented programming – intermediate elements

  • classes and objects – reinforcement,
  • inheritance and composition,
  • special methods (str, repr, len),
  • encapsulation and properties (property),
  • abstract classes and interfaces,
  • design patterns (introduction).

5. Working with files and paths

  • reading and writing files (text, CSV, JSON),
  • exception handling when working with files,
  • path management (os, pathlib),
  • operations on directories.

6. Date and time

  • datetime and time modules,
  • operations on dates and time,
  • date formatting,
  • time zones (introduction),
  • practical applications (schedules, logs).

7. Logging

  • basics of the logging module,
  • logging levels (DEBUG, INFO, ERROR),
  • logger configuration,
  • logging to a file,
  • good practices in projects.

8. Unit tests

  • introduction to testing,
  • unittest / pytest framework,
  • creating unit tests,
  • assertions and test scenarios,
  • mocking and testing dependencies.

9. Regular expressions

  • regex syntax,
  • searching and matching patterns,
  • groups and modifiers,
  • data validation,
  • text processing using regex**.

What are the prerequisites for participating in the training?

icon

Python syntax basics - You should be comfortable using variables, data types, conditionals, loops, and basic operations on lists and dictionaries when writing simple Python scripts.

icon

Simple function writing - You should know how to define and call your own functions, pass basic arguments, and understand return values as well as the idea of local variable scope.

icon

Basic module usage - You should understand how to import modules and use functions from the standard library, so you can follow examples that rely on built-in Python tools.

icon

Intro to classes and objects - You should know the basic ideas behind classes, objects and methods, so moving into inheritance, properties and more advanced OOP in Python will be easier.