Kebab Case a Phrase
Implement a function that converts a phrase into lowercase kebab-case, handling spaces, punctuation, and camelCase.
Stack Trace Sanitizer
Implement a function that rewrites traceback file paths to basenames only.
Extract Hashtags
Extract unique hashtags from a given text string in the order they appear.
Extract mentions
Extract unique @mentions from a string, respecting email-like patterns and punctuation.
Remove HTML tags
Remove all HTML tags from a string to extract clean text.
Find all numbers in text
Write a function that extracts all standalone integers from a text string using regular expressions.
Validate phone number
Write a function that uses regular expressions to determine if a given string is a valid US phone number.
Match IPv4 Address
Write a function that uses a regular expression to check if a string is a valid IPv4 address.
Validate Hex Color Code
Write a function that validates hex color codes using regular expressions.
Multiline anchor match
Extract lines beginning with a plain-text prefix from multiline strings using Python's re module.
Lookahead Validation
Write a regex-based function to check if a password meets length and character class requirements.
Showing 11 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.