Longest Substring with K Repeating Characters
Return the length of the longest substring of a given string in which every character appears at least K times.
Redundant Connection
Given a list of edges forming a tree plus one extra edge, return the edge that appears last in the input and creates a cycle.
AST Visitor Lite
Implement a depth-first traversal of a simplified AST and return identifier names in order.
Polynomial Fit Coefficients
Implement a function that returns the coefficients of the best-fit quadratic polynomial for given points.
Perfect Squares Sum
Given a positive integer n, return the least number of perfect squares (e.g., 1, 4, 9, 16, ...) that sum to n.
Integer Break Product
Given a positive integer n, break it into at least two positive integers that sum to n and maximize their product.
Count Complete Tree Nodes
Given a complete binary tree, return its node count faster than O(n) time.
All Paths from Source to Target
Given a directed acyclic graph, return all paths from node 0 to the last node.
Candy Distribution
Compute the minimum total candies needed so that every child gets at least one and children with higher ratings than neighbors get more candies.
Jump Game Reachable
Given an array of non-negative integers where each element is the maximum jump length, determine if you can reach the last index.
Search 2D Matrix
Given a sorted 2D matrix with sorted rows and first element of each row greater than last of previous, find target efficiently.
Minimum Size Subarray Sum
Given an array of positive integers, return the minimal length of a contiguous subarray with sum at least target, or 0 if none exists.
Asteroid Collision
Simulate asteroid collisions with a stack and return the remaining asteroids in original order.
Showing 13 challenges · medium
Guide: free Python coding challenges
Practice Python by solving problems
PythonSkillset challenges are hands-on coding exercises from beginner to advanced. Open a challenge, read the problem, write Python in the split-pane editor, and run tests with Pyodide — no install required.
How to use the arena
- Pick a category — basics, algorithms, strings, and more
- Open a challenge, read the statement, and edit the starter code
- Run tests, fix failures, then try a related quiz or tutorial lesson
Challenges vs tutorials and quizzes
Challenges test what you can build under constraints. For guided teaching, use our Python tutorials. For quick checks, try quizzes or copy snippets from code samples.