Single Number XOR
Given a non-empty list of integers where every element appears twice except one, return the single number using XOR.
Missing Number XOR
Given a list of n distinct numbers from 0 to n with one missing, use XOR to find and return the missing number.
House Robber
Given a list of house values, return the maximum sum you can rob without robbing two adjacent houses.
Triangle Minimum Path
Compute the minimum path sum from top to bottom of a triangle given as a list of lists.
Shortest Unsorted Continuous Subarray
Given an array of integers, return the length of the shortest contiguous subarray whose sorting makes the whole array sorted.
Search Insert Position
Return the index where a target should be inserted into a sorted list to maintain order.
Lower Bound Binary Search
Implement binary search to find the first index where an element is not less than a given target.
Upper Bound Binary Search
Write a function that returns the index of the first element greater than a target in a sorted list.
Best Time to Buy and Sell Stock
Given a list of daily stock prices, determine the maximum profit achievable by buying on one day and selling on a later day.
Reduce array to zero
Given an array of non-negative integers, each operation chooses two indices and subtracts 1 from each if both are positive. Return the minimum number of operations to reduce the array to all zeros, or -1 if impossible.
Next Greater Element
Return a list where each position holds the next greater element to the right, or -1 if none exists.
Element-wise vector addition
Add equal-length numeric lists element-wise.
Scale a vector by scalar
Multiply every element by k.
Dot product of two vectors
Return sum of element-wise products.
Mean of a vector
Return arithmetic mean or 0.0 when empty.
Maximum element in vector
Return largest value or None when empty.
Minimum element in vector
Return smallest value or None when empty.
Clip vector to range
Clamp each value to [lo, hi].
Min-max normalize vector
Scale values to 0..1; equal values become all 0.0.
Sum each matrix row
Given rows, return each row sum.
Sum each matrix column
Return column totals for a rectangular matrix.
Showing 25–45 of 45 challenges · easy
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.