0 (0 Ratings)

Introduction to Python Programming

Categories Programming, Python

What I will learn?

  • Set up Python and your development environment, then master core coding skills—variables, data types, functions, conditions, loops and organising reusable code.
  • Automate everyday jobs by working with files and folders, using popular libraries and driving web tasks with PyAutoGUI and Selenium.
  • Build smarter workflows to process Excel and PDF documents, send automated emails and alerts, and schedule your scripts to run on their own.
  • Bring it all together in a mini-project to create a complete automation tool, learn error-handling and debugging, and map out your career-growth path.

Course Curriculum

Introduction to Python Programming
In this Introduction to Python module, learners explore Python’s clear, readable syntax and powerful features. Beginning with installation and a simple “Hello, World!” script, you will progress through variables, control flow and functions using step-by-step examples. By the end, you will be equipped to write your own Python programmes, automate routine tasks and tap into an extensive library ecosystem for real-world projects.

  • Introduction to Python and Setup
  • Real-World Applications
  • Getting Started with Python
  • Running Python Code on Windows 11
  • Installing Python Modules
  • Quiz: Introduction to Python and Setup

Running Python Interactively
Imagine typing a few simple commands and seeing instant results as you use Python as a calculator or manipulate text with ease.

Variables, Data Types and Basic Operations
In the Variables, Data Types and Basic Operations in Python module, learners explore how to store and manage data using variables, master fundamental types such as integers, floats, strings and booleans, and perform arithmetic, comparison and logical operations step by step. Clear explanations, real world examples and hands on exercises guide you through writing and debugging code. By the end of this module, you will be ready to build dynamic Python programs and automate everyday tasks.

Control Flow – Conditions and Loops
Have you ever wondered how to make your Python programmes make decisions or repeat tasks automatically? In this lesson on Control Flow – Conditions and Loops, you will learn how to guide your code through different paths and loop over data sets. Mastering these tools is essential for everything from simple scripts to complex applications.

Pattern Matching with match Statements
Imagine you have different formats of data arriving in your programme and you need to run distinct code for each case. Python’s match statement lets you compare a value against several patterns, extract parts of that value into variables and then execute the first matching block. In this section on match statements, you will learn how to build clearer, more maintainable decision logic in your code.

Functions and Code Organisation
Imagine you need to clean up a messy data set or send a personalised email to each customer. Instead of writing the same steps over and over, you can create a function and call it whenever you need. In this lesson on Functions and Code Organisation, you will learn how to define functions, pass and return information, document your work and group related code into modules for easy reuse and maintenance.

Lab: Automating Daily Tasks with Conditions and Loops in Python
Imagine your computer tidying up old files for you each morning without any effort. Automating daily tasks with conditions and loops in Python lets you set rules, scan through data and act only when certain criteria are met. In this tutorial, you will build a simple file-cleanup script that removes files older than a set number of days. This will save you time and keep your folders organised.

Working with Files and Folders
Ever wanted to read from or write to a file with just a few lines of code? Python makes working with files and folders remarkably simple. Whether you are storing results from a script, loading configuration data or managing documents, this lesson will teach you how to open, read, write and organise file content effectively using Python’s built-in tools.

Introduction to Python Libraries
One of the best parts about Python is that it comes with heaps of useful tools built in—no need to download extra software for most everyday tasks. These ready-to-use tools are called libraries, and they make everything from maths and file management to internet access and error handling much easier.

Python’s Package Manager
Ever wondered how Python developers install powerful tools like NumPy, Pandas or Flask with just one command? That magic comes from pip, Python’s built-in package manager. In this lesson, you will learn what pip is, why it matters and how to find and use it effectively. Whether you are building a small script or a large application, pip helps you manage the libraries your project depends on.

Web Automation Basics with pyautogui and selenium
Imagine telling your computer to open a browser, click buttons, fill forms and even scroll pages—all without lifting a finger. In this lesson on Web Automation Basics with PyAutoGUI and Selenium, you will learn how to automate web interactions two ways: by controlling your mouse and keyboard with PyAutoGUI, and by driving a browser in the background with Selenium. These tools let you speed up repetitive tasks, gather data and test web pages efficiently.

Error Handling and Debugging Techniques
Have you ever run a Python script only to see a confusing error message pop up? Learning proper error handling and debugging techniques will help you spot issues, keep your code running smoothly and save you hours of troubleshooting. In this lesson you will learn about the two main kinds of errors in Python, how to catch and manage exceptions, and practical ways to debug your code effectively. Types of Errors in Python Python reports two primary kinds of errors: - Syntax Errors - Exceptions Understanding the difference between these will guide you to the right solution. Syntax Errors Syntax errors occur when Python cannot parse your code because it does not follow the language rules. They are detected before your programme even starts running. Example of a Syntax Error while True print("Hello") Python responds with: File "", line 1 while True ^ SyntaxError: invalid syntax Notice the caret (^) pointing to the issue. In this case you have forgotten the colon (:) after the while True statement. Fixing syntax errors is usually straightforward: read the message, find the line and correct the mistake. Exceptions Even if your code has perfect syntax, it may still fail when it runs. These failures are called exceptions. Common examples include dividing by zero, using undefined variables or mixing text with numbers. Common Exception Examples # Division by zero 10 * (1 / 0) # Name error for undefined variable 4 + spam * 3 # Type error when mixing string and integer '2' + 2 Each error shows a traceback, telling you where the exception occurred and its type, such as ZeroDivisionError, NameError or TypeError. Catching and Handling Exceptions Rather than letting your programme crash, you can use try and except blocks to manage exceptions gracefully. Basic try/except Example while True: try: x = int(input("Please enter a number: ")) break except ValueError: print("That was not a valid number. Try again.") How this works: - Python runs the code in the try block. - If no exception occurs, it skips the except block and continues. - If ValueError occurs (for example typing abc), Python jumps to the except block. - The loop repeats until valid input is given. Handling Multiple Exception Types You can catch different exceptions in separate except clauses or group them together. Separate Handlers try: f = open('data.txt') line = f.readline() number = int(line.strip()) except FileNotFoundError: print("File not found.") except ValueError: print("Could not convert data to an integer.") Grouped Exceptions try: # code that may raise several errors pass except (RuntimeError, TypeError, NameError) as err: print("Caught one of the expected errors:", err) Using specific exception types is considered best practice. Catching only what you expect helps you avoid hiding unexpected bugs. Using else and finally Clauses The else Clause You can add an else block that runs only if the try block did not raise an exception. This keeps your code organised by separating normal flow from error handling. try: result = compute_value() except ValueError: print("Invalid value.") else: print("Computation succeeded, result is", result) The finally Clause A finally block runs no matter what, even if an exception is not caught. It is ideal for cleanup tasks such as closing files. try: f = open('report.txt', 'r') process(f) except OSError: print("Error reading file.") finally: f.close() print("File closed.") Inspecting Exception Details When you catch an exception, you can access its attributes for more context. try: raise Exception('Something went wrong', 42) except Exception as inst: print("Type:", type(inst)) print("Arguments:", inst.args) x, y = inst.args print("First argument:", x) print("Second argument:", y) This prints the exception type, its arguments and unpacks them for further handling. Debugging Techniques Beyond exception handling, use these techniques to find and fix bugs faster: - Print Debugging Insert print() statements to display variable values and programme flow. - Logging Module Replace print() with the module for adjustable log levels and better record keeping. - Python Debugger (pdb) Insert import pdb; pdb.set_trace() in your code to step through execution interactively. - IDE Debuggers Use breakpoints and watches in IDEs like VS Code or PyCharm for a graphical debugging experience. - Automated Testing Write tests with or to catch regressions and ensure your code works as expected. Summary In this lesson on error handling and debugging techniques you have learned to: - Distinguish between syntax errors and exceptions - Use try, except, else and finally to manage errors - Catch specific exception types and inspect their details - Apply practical debugging methods like print statements, logging and interactive debuggers With these tools, you can write more robust Python code and troubleshoot issues confidently. Next, we will dive into working with files and folders to automate data processing tasks.

Lab: Automating File and Folder Operations
Imagine your Downloads folder overflowing with documents, images and spreadsheets. Instead of sorting everything by hand, let Python do the heavy lifting. In this lab on Automating File and Folder Operations, you will write a script that organises files into subfolders based on their file type. You will learn how to inspect folders, create new directories, and move files—skills that you can adapt to many real-world tasks

Automating Excel and PDFs with Python
Imagine scanning a folder full of spreadsheets and PDF reports, then having a script organise, combine and extract the data for you in seconds. Automating Excel and PDFs with Python can save hours of manual work and reduce errors. In this lesson you will learn how to read, write and analyse Excel files with openpyxl and pandas, merge and split PDFs with PyPDF2, and create simple PDF reports with reportlab.

Automating Email Notifications
Automating email notifications with Python lets you generate and dispatch messages automatically, saving time and cutting down on mistakes. In this lesson, you will learn how to compose emails, add attachments and send them through an SMTP server—all with just a few lines of code.

Scheduling and Running Scripts Automatically
Scheduling and running scripts automatically can make that a reality. In this lesson, you will learn how to turn your Python scripts into hands-free tasks, using built-in techniques on macOS, Linux and Windows, as well as Python libraries.

Mini Project: Build your own Automation Tool
Here are a handful more project ideas. These are simple, real‑world automation challenges that build on fundamentals and gently grow your skills.

Career Tips and Learning Path
Ready to turn your newfound Python and automation skills into a rewarding career? In this guide on Career Tips and Learning Path, you will discover practical advice for landing roles in automation or software development, and a step-by-step roadmap for advancing from beginner to specialist.

Student Ratings & Reviews

No Review Yet
No Review Yet
$150.00

Material Includes

  • Downloadable code samples

Requirements

  • Basic computer skills and familiarity with file navigation
  • A computer running Windows, macOS or Linux with an internet connection
  • Python installed from python.org
  • Choice of code editor or IDE such as VS Code, Jupyter Notebook or PyCharm
  • Willingness to learn by doing and follow step-by-step labs

Target Audience

  • Complete beginners with no prior programming experience
  • Professionals who want to automate repetitive tasks
  • Students studying IT or data-focused disciplines
  • Anyone interested in learning Python for web, data or process automation