Min of three numbers
Write a function that returns the minimum of three integers.
Seconds to Hours Minutes Seconds
Convert total seconds into a zero-padded HH:MM:SS format.
Minutes to Hours: Time Conversion Helper
Write a function that converts minutes into a human-readable 'Xh Ym' string, with special cases for zero and whole hours.
Find Minimum Value
Write a function that returns the minimum integer from a given list.
Range of values
Calculate the range (max minus min) of a list of numbers. Empty list returns 0.
Is pangram
Write a function that determines whether a given string is a pangram, ignoring case and non-letter characters.
Is isogram
Implement a function that determines whether a string is an isogram (no repeated letters, case-insensitive).
Is rotation of another string
Write a function to determine if one string is a rotation of another string.
Hamming Distance
Implement a function that computes the Hamming distance between two strings of equal length.
Average excluding min and max
Return the average of a list after discarding the lowest and highest elements, handling edge cases.
Merge dicts summing values
Write a function that merges two dictionaries by summing values for duplicated keys.
Count Pairs with Sum
Implement a function that counts the number of distinct pairs in a list summing to a target.
Ransom Note Builder
Given two strings, determine if the ransom note can be formed from the words in the magazine.
Timing Decorator
Implement a decorator that prints the execution time of a function.
Context Manager Class
Implement a context manager class that measures execution time and sets duration, with None if an exception occurred.
Timer Context Manager
Implement a context manager that measures execution time of a with block and stores it.
Context Decorator Dual
Implement a timing decorator and a context manager that both record elapsed time in seconds.
Validate phone number
Write a function that uses regular expressions to determine if a given string is a valid US phone number.
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).
Lucas Sequence
Implement a function to compute the n-th Lucas number using iteration or recursion with memoization.
Add without plus
Implement a function that adds two integers using only bitwise operations, no arithmetic plus or minus.
Min cost climbing stairs
Compute the minimum total cost to reach the top of a staircase, given you can climb 1 or 2 steps at a time.
House Robber
Given a list of house values, return the maximum sum you can rob without robbing two adjacent houses.
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.
Triangle Minimum Path
Compute the minimum path sum from top to bottom of a triangle given as a list of lists.
Minimum Depth of Tree
Given a binary tree, compute the minimum depth from the root to the nearest leaf node.
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.
Min Heap Class
Build a MinHeap class with push, pop, peek, and size methods that maintain a valid min-heap.
Valid Sudoku Board
Determine if a 9x9 Sudoku board is valid by checking rows, columns, and 3x3 sub-boxes.
Showing 30 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.