Set symmetric difference
Write a function that returns the elements found in exactly one of two sets, sorted ascending.
Rank Employees by Salary
Sort a list of employee dictionaries by salary descending, tie-break by name, and return ranked strings.
Order by Name
Implement a function that sorts a list of names alphabetically ignoring case, returning a new list.
Anagram check
Return True if two strings are anagrams of each other.
Sort characters alphabetically
Sort all characters in a string alphabetically and return the sorted string.
Sort characters in string
Write a function that sorts the characters in a string and returns the sorted string.
Custom Sort String
Given a string s and an order string, reorder s so that characters that appear in order come first in that order, and all other characters are appended in stable original order.
Parse range notation
Parse a comma-separated list of ranges and individual numbers, expanding each range into its full sequence.
Second Largest Unique Value
Return the second largest distinct integer from a list, or None if it doesn't exist.
Average excluding min and max
Return the average of a list after discarding the lowest and highest elements, handling edge cases.
Find Second Largest
Find the second largest unique number in a list, or None if it doesn't exist.
Move Zeros to End
Rearrange a list by moving all zeros to the end while preserving the relative order of non-zero elements.
Intersection of Two Lists
Given two lists, return a sorted list of unique elements that appear in both lists.
Wave sort array
Given a list of integers, reorder it into a wave pattern where elements alternate down-up, and return the new list.
Counting Sort
Implement the counting sort algorithm to sort a list of non-negative integers in O(n + k) time.
Count Smaller Numbers
Given an integer list, return for each position how many later elements are smaller than it.
Sort array by parity
Given a list of integers, return a new list with all evens first and odds last, preserving original relative order.
Merge Sorted Array In Place
Write a function that merges two sorted arrays into the first array in-place, keeping the result sorted.
Cartesian Product Pairs
Create a function that returns the Cartesian product of two lists as a sorted list of lists.
Sort List Merge Sort
Write a function that sorts a list of integers using the merge sort algorithm.
Insertion Sort
Implement insertion sort that sorts a list in-place and returns the same list.
Group anagrams
Group words that are anagrams of each other.
Keys Sorted by Value Descending
Given a dictionary mapping strings to integers, return a list of keys sorted by value descending, and when values tie, alphabetically ascending.
Common Keys of Two Dictionaries
Implement a function that finds keys shared by two dictionaries and returns them sorted.
Showing 1–24 of 73 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.