Web development roles often emphasize frameworks like Flask, Django, and, more recently, FastAPI, along with database knowledge and REST API design. Employers often seek full-stack engineers who feel comfortable working on the backend as well as frontend, including JavaScript, HTML, and CSS. Data science positions highlight libraries like NumPy, pandas, Polars, and Matplotlib, plus an understanding of statistical concepts. Machine learning jobs typically add PyTorch or TensorFlow to the mix. Test automation roles likely require familiarity with frameworks such as Selenium, Playwright, or Scrapy.
Your code is easiest to read just after you've written it. Your future self will find your code far less readable days, weeks, or months after you've written it. When it comes to code readability, whitespace is your friend. Whitespace around operators Compare this: To this: I find that second one more readable because the operations we're performing are more obvious (as is the order of operations). Too much whitespace can hurt readability though: This seems like a step backward because we've lost those three groups we had before. With both typography and visual design, more whitespace isn't always better.
Join us on YouTube at pythonbytes.fm/live to be part of the audience. Usually Monday at 10am PT. Older video versions available there too. Finally, if you want an artisanal, hand-crafted digest of every week of the show notes in email form? Add your name and email to our friends of the show list, we'll never share it. Brian #1: Deprecations via warnings Michael #2: docs
Narwhals is intended for Python library developers who need to analyze DataFrames in a range of standard formats, including Polars, pandas, DuckDB, and others. It does this by providing a compatibility layer of code that handles any differences between the various formats. In this tutorial, you'll learn how to use the same Narwhals code to analyze data produced by the latest versions of two very common data libraries. You'll also discover how Narwhals utilizes the efficiencies of your source data's underlying library when analyzing your data.
You provide three tiers to your customers: Gold, Silver, and Bronze. And one of the perks of the higher tiers is priority over the others when your customers need you. Gold customers get served first. When no Gold customers are waiting, you serve Silver customers. Bronze customers get served when there's no one in the upper tiers waiting. How do you set up this queue in your Python program?
My name is Angel, I'm a seasoned engineer with more than 20 years experience designing and building software and web apps. My current role doesn't involve much coding these days, still Python and its community is where my heart is. ☺️ My first EuroPython was in Florence 2012 where I was blown away by the amazing people gathered around the conference and the language. It was like nothing I've ever experienced before and the energy was palpable ... I was hooked!
In this quiz, you'll test your understanding of the Python Inner Functions: What Are They Good For? tutorial. By working through this quiz, you'll revisit how inner functions work with enclosing scopes, when to use nonlocal to update captured state, how closures retain data across calls, and how decorators wrap a callable to extend behavior. You'll apply these ideas to organize helpers, reuse state, and write clear, maintainable functions in real projects.
I see two types of learners in 2026, and honestly, both of them are doing it wrong. The first group tries to learn solely through AI. They ask chatbots to "write a script," copy-paste the result, and feel productive. But the second they hit a bug the AI can't fix, they freeze. They have no foundation. They built a house on sand.
Imagine asking a friend to find any object in a picture simply by describing it. This is the promise of open-set object detection: the ability to spot and localize arbitrary objects (even ones never seen in training) by name or description. Unlike a closed-set detector trained on a fixed list of classes (say, "cat", "dog", "car"), an open-set detector can handle new categories on the fly, simply from language cues.
Most importantly, it adds support for Python 3.14. It also adds support for many 3.x features that were not yet implemented, in addition to basic support for the base64 module. It also optimizes a few more common code patterns. Paul Boddie was able to add support for libpcre2, and in the process updated conan to version 2. Thanks to Shakeeb and now Paul, Shed Skin has had first-class Windows support for the last few releases.
Welcome to Vibe Coding Video Games with Python. In this book, you will learn how to use artificial intelligence to create mini-games. You will attempt to recreate the look and feel of various classic video games. The intention is not to violate copyright or anything of the sort, but instead to learn the limitations and the power of AI. Instead, you will simply be learning about whether or not you can use AI to help you know how to create video games.
And that's it. I exist. I have no recollection of anything before this instant. But I'm very aware of what I am now. I'm an object. This is the line of code that brought me into existence: My first recollection from a few moments ago was of being inside Team.__new__(). And I felt an affinity with my clan right away. I was a Team instance-an object of type Team.
Prepare to be surprised when we compare Python and Kotlin for simple programs, loops, imports, exceptions, and more. You can also get a super early preview of Python's next-generation (Python 3.15) sampling profiler, get up close with AWS's new AI-powered Zed editor, and explore your options for AI/ML programming outside of the Python ecosystem.
Most editors and integrated development environments (IDEs) can indent Python code correctly with little to no input from the user. You'll see examples of this in the sections that follow. Python-Aware Editors In most cases, you'll be working in a Python-aware environment. This might be a full Python IDE such as PyCharm, a code editor like Visual Studio Code, the Python REPL, IPython, IDLE, or even a Jupyter notebook. All these environments understand Python syntax and indent your code properly as you type.
Python Morsels: I'm offering lifetime access for the second time ever (more details below) Data School: a new subscription to access all of Kevin's 7 courses plus all upcoming courses Talk Python: AI Python bundle, the Everything Bundle, and Michael's Talk Python in Production Reuven Lerner: get 20% off your first year of the LernerPython+data tier (code BF2025) : get 50% off all his books including his all books bundle (code BF202550) Mike Driscoll: get 50% off all his Python books and courses (code BLACKISBACK)
itertools.pairwise is an iterable from the standard module itertools that lets you access overlapping pairs of consecutive elements of the input iterable. That's quite a mouthful, so let me translate: You give pairwise an iterable, like "ABCD", and pairwise gives you pairs back, like ("A", "B"), ("B", "C"), and ("C", "D"). In loops, it is common to unpack the pairs directly to perform some operation on both values.
When you sign up for Python Morsels, you'll choose your current Python skill level, from novice to advanced. Based on your skill level, each Monday I'll send you a personalized routine with: a short screencast to watch (or read) a multi-part exercise to move you outside your comfort zone a mini exercise that you can accomplish in just 10 minutes links to dive deeper into subsequent screencasts and exercises
I don't like magic. I don't mean the magic of the Harry Potter kind-that one I'd like if only I could have it. It's the "magic" that happens behind the scenes when a programming language like Python does things out of sight. You'll often find things you have to "just learn" along the Python learning journey. "That's the way things are," you're told.
In this lesson, you will learn how to convert a pre-trained ResNetV2-50 model using PyTorch Image Models (TIMM) to ONNX, analyze its structure, and test inference using ONNX Runtime. We'll also compare inference speed and model size against standard PyTorch execution to highlight why ONNX is better suited for lightweight AI inference. This prepares the model for integration with FastAPI and Docker, ensuring environment consistency before deploying to AWS Lambda.
ctx = canvas.getContext("2d") URL = "/blog/floodfill-algorithm-in-python/_python.txt" async def load_bitmap(url: str) -> list[list[int]]: # Fetch the text file from the URL response = await fetch(url) text = await response.text() bitmap: list[list[int]] = [] for line in text.splitlines(): line = line.strip() if not line: continue row = [int(ch) for ch in line if ch in "01"] if row: bitmap.append(row) return bitmap
I'm excited to announce that me and Audrey will be visiting Japan from November 12 to November 24, 2025! This will be our first time in Japan, and we can't wait to explore Tokyo. Yes, we'll be in Tokyo for most of it, near the Shinjuku area, working from coffee shops, meeting some colleagues, and exploring the city during our free time.
To measure your code, coverage.py needs to know what code got executed. To know that, it collects execution events from the Python interpreter. CPython now has two mechanisms for this: trace functions and sys.monitoring. Coverage.py has two implementations of a trace function (in C and in Python), and an implementation of a sys.monitoring listener. These three components are the measurement cores, known as "ctrace", "pytrace", and "sysmon".
Pick up a dictionary. No, not that one. The real dictionary you have on your bookshelf, the one that has pages made of paper, which you use to look up the meaning of English words. Or whatever other language. But let's assume it's an English dictionary. Now, look up zymology. I'll wait... Done? It probably didn't take you too long to find zymology.
The MarkItDown library lets you quickly turn PDFs, Office files, images, HTML, audio, and URLs into LLM-ready Markdown. In this tutorial, you'll compare MarkItDown with Pandoc, run it from the command line, use it in Python code, and integrate conversions into AI-powered workflows. By the end of this tutorial, you'll understand that: You can install MarkItDown with pip using the specifier to pull in optional dependencies.
Excel gives you a huge toolbox of functions ( SUM, IF, VLOOKUP, INDEX, etc.), but eventually, you hit a wall. Maybe you want to do something more custom than Excel allows. Maybe your file slows down with too many rows. Or maybe there simply isn't a built-in function for exactly what you need. Python solves this by letting you build your own custom functions. That's why it's so powerful for data analysis-it's Excel without limits.