Practice Arena

Python Coding Challenges

Write real Python in the browser. Instant feedback. From beginner to expert.

925 challenges 556 easy 323 medium 46 hard
Dynamic Programming medium

Levenshtein Distance

Implement the classic Levenshtein distance algorithm to measure string similarity.

strings dynamic-programming edit-distance
+30 pts 30m
Dynamic Programming medium

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.

dynamic-programming strings levenshtein-distance
+25 pts 30m
Graphs & Graph Algorithms medium

Bellman-Ford Algorithm

Implement the Bellman-Ford algorithm to compute shortest distances from a source in a directed weighted graph with up to 100 vertices and negative edges.

shortest-path negative-edges graph
+30 pts 30m
Graphs & Graph Algorithms medium

Floyd-Warshall: All-Pairs Shortest Paths

Implement the Floyd-Warshall algorithm to find all-pairs shortest path distances in a directed graph with possibly negative weights but no negative cycles.

graph shortest-path dynamic-programming
+25 pts 30m
Binary Search medium

Magnetic Force Packages

Given basket positions and k balls, find the largest possible minimum distance between any two balls.

binary-search greedy array
+30 pts 30m
Binary Search medium

Minimum Speed to Arrive on Time

Given commute distances and a time limit, compute the minimum integer speed so you arrive on time.

binary-search simulation math
+25 pts 30m
Matrix & 2D Arrays medium

01 Matrix Nearest Zero

Given a binary matrix, return a matrix of the same shape where each cell contains the Manhattan distance to the nearest 0.

matrix bfs distance
+25 pts 30m

Showing 1–7 of 7 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

  1. Pick a category — basics, algorithms, strings, and more
  2. Open a challenge, read the statement, and edit the starter code
  3. 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.