Catalan number
Implement a function that returns the nth Catalan number using dynamic programming.
Stirling number
Implement a function to compute Stirling numbers of the second kind S(n,k).
Levenshtein Distance
Implement the classic Levenshtein distance algorithm to measure string similarity.
House Robber
Given a list of house values, return the maximum sum you can rob without robbing two adjacent houses.
House Robber Circular
Solve the House Robber problem with houses arranged in a circle.
Unique Paths in a Grid
Count the number of unique paths from the top-left corner to the bottom-right corner of a grid, moving only right and down.
Unique Paths with Obstacles
Given a 2D grid with obstacles, count the unique paths from top-left to bottom-right moving only down or right.
Triangle Minimum Path
Compute the minimum path sum from top to bottom of a triangle given as a list of lists.
Maximal square
Given a 2D binary matrix of 0s and 1s, compute the area of the largest square containing only 1s.
Longest Common Subsequence
Given two strings, compute the length of the longest subsequence common to both.
Longest Palindromic Subsequence
Compute the length of the longest palindromic subsequence in a given string.
Edit Distance (Levenshtein Distance)
Implement the classic edit distance algorithm to find the minimum number of single-character edits required to transform one string into another.
0/1 Knapsack
Implement the classic 0/1 Knapsack dynamic programming solution to maximize value under a weight capacity.
Unbounded Knapsack
Given item weights and values with unlimited copies, find the maximum total value that fits in a knapsack capacity.
Partition Equal Subset
Determine whether a given list of positive integers can be partitioned into two subsets with equal sum.
Coin Change Minimum
Given coin denominations and a target amount, compute the minimum number of coins needed or -1 if impossible.
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.
Word Break DP
Implement a function to check if a string can be segmented into space-separated dictionary words.
Palindrome Partitioning Minimum Cuts
Given a string, return the minimum number of cuts needed such that every substring in the partition is a palindrome.
Egg Drop Puzzle
Given k eggs and n floors, compute the minimum number of attempts required in the worst case to find the highest safe floor.
Paint House Colors
Given a cost matrix, compute the minimum total cost to paint all houses with no two adjacent houses having the same color.
Buy Sell Stock with Cooldown (DP)
Given daily stock prices, compute the maximum profit you can achieve if you must wait one day after selling before buying again.
Showing 23 challenges
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.