ROT13 transform
Implement the ROT13 cipher on a string, preserving case and leaving non-letters unchanged.
Additive number sequence
Check whether a given digit string can be partitioned into a valid additive sequence where each term is the sum of the previous two.
Crawler Log Folder
Given a list of folder navigation operations, compute the minimum steps required to return to the main folder.
Parse Hex Dump
Write a function that parses a hex dump string into a list of integers.
Caesar Cipher Decrypt
Write a function that decrypts a Caesar cipher by shifting letters backward by a given key.
Group anagrams
Group words that are anagrams of each other.
First non-repeating character
Find the index of the first character that appears only once.
Group names by first letter
Given a list of names, return a dictionary mapping each first letter to all names starting with that letter in original order.
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.
Anagram Dictionary Groups Lite
Group a list of words into anagrams using a dictionary keyed by sorted characters.
Anagram Groups by Size
Group a list of words into anagram groups and return them sorted by group size and lexicographically.
Top K Frequent Words
Given a list of words, return the k most frequent words sorted by frequency (descending) and then alphabetically.
Ransom Note Builder
Given two strings, determine if the ransom note can be formed from the words in the magazine.
Pivot sales by product
Write a function that pivots sales records into a dictionary keyed by product with monthly totals.
Complex Number Class
Implement a Complex class supporting addition, subtraction, multiplication, division, equality, and string formatting.
String Representation Mixin
Implement a mixin class that provides generic __repr__ and __str__ based on instance attributes.
Valid parentheses
Return True if brackets in the string close in the correct order.
Word ladder length
Return the length of the shortest transformation from beginWord to endWord changing one letter at a time.
Decode Ways
Count the number of ways to decode a numeric string into letters using the mapping A=1 to Z=26.
Basic Calculator II
Evaluate a basic arithmetic expression with +, -, *, / following operator precedence.
Strobogrammatic number II
Given a positive integer n, return all strobogrammatic numbers of length n in ascending order.
Safe Integer from String
Implement safe_int that converts a string to an integer, returning a default value on any failure, with support for an optional base.
Safe int parser
Implement safe_parse_int that converts a string to an int, returning a default value on failure.
Safe Float Parser
Write a function that safely converts a string to a float, returning None for invalid inputs.
Showing 121–144 of 219 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.