Defining Your Own Python Function

Watch Now This tutorial has a related video course created by the Real Python team. Watch it together with the written tutorial to deepen your understanding: Defining and Calling Python Functions A Python function is a named block of code that performs specific tasks and can be reused in other parts of your code. Python has several built-in functions that are always available, and you can also create your own. These are known as user-defined functions. To define a function […]

Read more

Python Continuous Integration and Deployment Using GitHub Actions

Creating software is an achievement worth celebrating. But software is never static. Bugs need to be fixed, features need to be added, and security demands regular updates. In today’s landscape, with agile methodologies dominating, robust DevOps systems are crucial for managing an evolving codebase. That’s where GitHub Actions shine, empowering Python developers to automate workflows and ensure their projects adapt seamlessly to change. GitHub Actions for Python empowers developers to automate workflows efficiently. This enables teams to maintain software quality […]

Read more

Python Hits the Big Screen and Other Python News for June 2025

A newly announced documentary brings Python’s history and culture to the screen, offering a rare behind-the-scenes look at the people and philosophies that shaped it. Meanwhile, new releases and PEPs continue to drive the evolution in packaging and language design. Conferences also continue to foster inclusion, learning, and connection. With new leadership at the PSF and a slate of impactful updates, the Python community is clearly energized and looking ahead. Let’s dive into the biggest developments shaping Python this month. […]

Read more

BenchmarkQED: Automated benchmarking of RAG systems

One of the key use cases for generative AI involves answering questions over private datasets, with retrieval-augmented generation (RAG) as the go-to framework. As new RAG techniques emerge, there’s a growing need to benchmark their performance across diverse datasets and metrics.  To meet this need, we’re introducing BenchmarkQED, a new suite of tools that automates RAG benchmarking at scale, available on  

Read more

Quiz: How to Find an Absolute Value in Python

Interactive Quiz ⋅ 9 QuestionsBy Bartosz Zaczyński Share In this quiz, you’ll test your understanding of How to Find an Absolute Value in Python. By working through this quiz, you’ll revisit key concepts such as how to use Python’s built-in functions to compute absolute values, apply them in mathematical operations, and handle different data types effectively. The quiz contains 9 questions and there is no time limit. You’ll get 1 point for each correct answer. At the end of the […]

Read more

Quiz: How Can You Structure Your Python Script?

Interactive Quiz ⋅ 11 QuestionsBy Bartosz Zaczyński Share In this quiz, you’ll test your understanding of the tutorial How Can You Structure Your Python Script? By working through this quiz, you’ll revisit best practices for organizing your Python scripts, including setting up the main entry point, using imports effectively, and writing code that can be reused as modules or run as standalone scripts. The quiz contains 11 questions and there is no time limit. You’ll get 1 point for each […]

Read more

Execute Your Python Scripts With a Shebang

In shell scripts, the shebang line (#!) specifies the path to the interpreter that should execute the file. You can place it at the top of your Python file to tell the shell how to run your script, allowing you to execute the script directly without typing python before the script name. The shebang is essential for Unix-like systems but ignored on Windows unless using specific compatibility layers. By the end of this video course, you’ll understand that: A shebang […]

Read more

How Can You Structure Your Python Script?

You may have begun your Python journey interactively, exploring ideas within Jupyter Notebooks or through the Python REPL. While that’s great for quick experimentation and immediate feedback, you’ll likely find yourself saving code into .py files. However, as your codebase grows, your Python script structure efficiency becomes increasingly important. Transitioning from interactive environments to structured scripts helps promote readability, enabling better collaboration and more robust development practices. This tutorial transforms messy scripts into well-organized, shareable code. Along the way, you’ll […]

Read more
1 2 3 926