Online Python Challenges
# It's time to create our first for-loop. Add
# the missing code to iterate over all weekdays.
days = ('Mo', 'Tu', 'We', 'Th', 'Fr', 'Sa', 'Su')
# add code here...
for
print(day)
Setting up Python environment...
Select Python Challenge
- Hello WorldPython BasicsFirst Steps
- Assign a value to a variablePython BasicsFirst Steps
- Create a variablePython BasicsFirst Steps
- Assign new value to a variablePython BasicsFirst Steps
- Get value of variable IPython BasicsFirst Steps
- Get value of variable IIPython BasicsFirst Steps
- Fix variable syntax mistakePython BasicsFirst Steps
- Exercise: Comment out line of codePython BasicsFirst Steps
- Subtract two variablesPython BasicsOperators I
- Raise to the power ofPython BasicsOperators I
- Change the order of mathematical evaluationPython BasicsOperators I
- Exercise: Floor Division OperatorPython BasicsOperators I
- Exercise: Relationship Floor Division and ModuloPython BasicsOperators I
- Exercise: Use plus-equal operator to shorten the codePython BasicsOperators I
- Exercise: Use times-equal operator to shorten the codePython BasicsOperators I
- Exercise: Create a string and store it in a variablePython BasicsStrings I
- Exercise: Different ways to create Python stringsPython BasicsStrings I
- Exercise: Concatenate strings IPython BasicsStrings I
- Exercise: Concatenate strings IIPython BasicsStrings I
- Exercise: Concatenate strings IIIPython BasicsStrings I
- Exercise: Get first character from stringPython BasicsStrings I
- Exercise: Get last character from stringPython BasicsStrings I
- Exercise: Extract range from string IPython BasicsStrings I
- Exercise: Extract range from string IIPython BasicsStrings I
- Exercise: Extract range from string IIIPython BasicsStrings I
- Exercise: Get length of stringPython BasicsStrings I
- Exercise: Concatenate strings and get lengthPython BasicsStrings I
- Exercise: Find the alphabet within gibberishPython BasicsStrings I
- Exercise: Clean up gibberish IPython BasicsStrings I
- Exercise: Clean up gibberish IIPython BasicsStrings I
- Exercise: Create Boolean and print its typePython BasicsBooleans
- Exercise: Comparison operators - EqualPython BasicsBooleans
- Exercise: Check if strings have same lengthPython BasicsBooleans
- Exercise: Check if string starts with letterPython BasicsBooleans
- Exercise: Check if number is evenPython BasicsBooleans
- Exercise: Comparison operators - Not EqualPython BasicsBooleans
- Exercise: Comparison operators - Greater ThanPython BasicsBooleans
- Exercise: Check if a Number is in a RangePython BasicsBooleans
- Exercise: Logical operators - and IPython BasicsBooleans
- Exercise: Logical operators - and IIPython BasicsBooleans
- Exercise: Logical operators - orPython BasicsBooleans
- Exercise: Logical operators - notPython BasicsBooleans
- Exercise: Combine logical operatorsPython BasicsBooleans
- Exercise: if statement - satisfy conditionPython BasicsConditionals I
- Exercise: if statement - add missing conditionPython BasicsConditionals I
- Exercise: Assign Value Based on ConditionPython BasicsConditionals I
- Exercise: else statement - run elsePython BasicsConditionals I
- Exercise: Add elif blockPython BasicsConditionals I
- Exercise: Test multiple conditions in if statementPython BasicsConditionals I
- Exercise: Call existing functionPython BasicsFunctions I
- Exercise: Fix function definitionPython BasicsFunctions I
- Exercise: Correctly return value from functionPython BasicsFunctions I
- Exercise: Create missing functionPython BasicsFunctions I
- Exercise: Exit function earlyPython BasicsFunctions I
- Exercise: Function Parameters and ArgumentsPython BasicsFunctions I
- Exercise: Create Function with ParameterPython BasicsFunctions I
- Exercise: Multiple Function Parameters and ArgumentsPython BasicsFunctions I
- Exercise: Default parameter valuePython BasicsFunctions I
- Exercise: Create Python List IPython BasicsLists and Tuples
- Exercise: Create Python List IIPython BasicsLists and Tuples
- Exercise: Create Python List IIIPython BasicsLists and Tuples
- Exercise: Dynamically Create ListsPython BasicsLists and Tuples
- Exercise: Create function to get last element of listPython BasicsLists and Tuples
- Exercise: Update element in listPython BasicsLists and Tuples
- Exercise: Update multiple elements in listPython BasicsLists and Tuples
- Exercise: Append element to listPython BasicsLists and Tuples
- Exercise: Insert element into listPython BasicsLists and Tuples
- Exercise: Find index of elementPython BasicsLists and Tuples
- Exercise: Conditionally remove element from listPython BasicsLists and Tuples
- Exercise: Create for-loopPython BasicsLoops
- Exercise: Use for-loop to get sum of numbersPython BasicsLoops
- Exercise: Filter sequence of names with for-loopPython BasicsLoops
- Exercise: Reverse string with for-loopPython BasicsLoops
- Exercise: Terminate for-loop with breakPython BasicsLoops
- Exercise: Skip iteration with continuePython BasicsLoops
- Exercise: Create nested for-loopPython BasicsLoops
- Exercise: Create while-loopPython BasicsLoops
- Convert while-loop into for-loopPython BasicsLoops
- Exercise: Add missing key-value pair to dictionaryPython BasicsDictionaries
- Exercise: Fill empty dictionaryPython BasicsDictionaries
- Exercise: Create dictionaryPython BasicsDictionaries
- Exercise: Create dictionary with variablesPython BasicsDictionaries
- Exercise: Create dictionary with functionPython BasicsDictionaries
- Exercise: Access dictionary valuePython BasicsDictionaries
- Exercise: Access nested dictionary valuePython BasicsDictionaries
- Exercise: Check if dictionary has keyPython BasicsDictionaries
- Exercise: Add key-value pair to dictionaryPython BasicsDictionaries
- Exercise: Update key-value pair in dictionaryPython BasicsDictionaries
- Exercise: Remove key-value pair from dictionaryPython BasicsDictionaries
- Exercise: Count total number of characters of dictionary keysPython BasicsDictionaries
- Exercise: Check if value exists in dictionaryPython BasicsDictionaries
- Exercise: Swap dictionary keys and valuesPython BasicsDictionaries
- Exercise: Filter dictionary by valuePython BasicsDictionaries
- Get nth character of stringPython BasicsTime to Practice I
- Count vowels in a stringPython BasicsTime to Practice I
- Count Occurrences in TuplePython BasicsTime to Practice I
- Remove duplicates in a stringPython BasicsTime to Practice I
- Voting agePython BasicsTime to Practice I
- Average score studentPython BasicsTime to Practice I
- Average score classPython BasicsTime to Practice I
- Count downPython BasicsTime to Practice I
- Sum of natural numbersPython BasicsTime to Practice I
- Find the Next Number Divisible by yPython BasicsTime to Practice I
- Calculate minutes between day timesPython BasicsTime to Practice I
- Escape quotes in a dialogueIntermediate PythonStrings II
- Print a Multiline Ingredient ListIntermediate PythonStrings II
- Exercise: String SplitIntermediate PythonStrings II
- Extracting Domain from EmailIntermediate PythonStrings II
- Word counterIntermediate PythonStrings II
- Find longest word in a textIntermediate PythonStrings II
- Transform to f-stringIntermediate PythonStrings II
- Transform to f-string IIIntermediate PythonStrings II
- Format number with f-stringsIntermediate PythonStrings II
- Create formatted table using f-stringsIntermediate PythonStrings II
- Exercise: Unpacking a tupleIntermediate PythonUnpacking
- Swap values between two variablesIntermediate PythonUnpacking
- Exercise: Unpacking a Full NameIntermediate PythonUnpacking
- Remove Values from a List Using UnpackingIntermediate PythonUnpacking
- Removing Middle Names Using UnpackingIntermediate PythonUnpacking
- Correctly Access Local VariableIntermediate PythonFunctions II
- Modify a Global Variable Inside a FunctionIntermediate PythonFunctions II
- Create a Global Variable Inside a FunctionIntermediate PythonFunctions II
- Exercise: Nested Function NamingIntermediate PythonFunctions II
- Correctly Call Nested FunctionIntermediate PythonFunctions II
- Create Nested FunctionIntermediate PythonFunctions II
- Encapsulate Existing FunctionIntermediate PythonFunctions II
- Exercise: Enclosing ScopeIntermediate PythonFunctions II
- Exercise: Enclosing Scope IIIntermediate PythonFunctions II
- Exercise: Scope HierarchyIntermediate PythonFunctions II
- Exercise: Python ClosureIntermediate PythonFunctions II
- Simple Counter with ClosuresIntermediate PythonFunctions II
- Exercise: Find maximum value of iterableIntermediate PythonWorking With Iterables
- Exercise: Find maximum key in dictionaryIntermediate PythonWorking With Iterables
- Exercise: Find minimum value in dictionaryIntermediate PythonWorking With Iterables
- Exercise: Get sum of tupleIntermediate PythonWorking With Iterables
- Exercise: Calculate the average valueIntermediate PythonWorking With Iterables
- Exercise: List Comprehension IIntermediate PythonWorking With Iterables
- Exercise: List Comprehension IIIntermediate PythonWorking With Iterables
- Exercise: List Comprehension IIIIntermediate PythonWorking With Iterables
- Exercise: Create lambda function IIntermediate PythonFunctions III
- Exercise: Create lambda function IIIntermediate PythonFunctions III
- Exercise: Create lambda function IIIIntermediate PythonFunctions III
- Exercise: Map function IIntermediate PythonFunctions III
- Exercise: Map function IIIntermediate PythonFunctions III
- Exercise: Map function IIIIntermediate PythonFunctions III
- Import NumPy LibraryBasic Data AnalysisNumPy
- Create NumPy Array IBasic Data AnalysisNumPy
- Indexing NumPy Array IBasic Data AnalysisNumPy
- Indexing NumPy Array IIBasic Data AnalysisNumPy
- Create NumPy Array IIBasic Data AnalysisNumPy
- Create NumPy Array IIIBasic Data AnalysisNumPy
- Slice 2D NumPy ArrayBasic Data AnalysisNumPy
- Update NumPy array elementBasic Data AnalysisNumPy
- Update multiple NumPy array elementsBasic Data AnalysisNumPy
- Filter NumPy arrayBasic Data AnalysisNumPy
- Create NumPy array with pattern IBasic Data AnalysisNumPy
- Create NumPy array with pattern IIBasic Data AnalysisNumPy
- Create NumPy array with pattern IIIBasic Data AnalysisNumPy
- Create first plotBasic Data AnalysisMatplotlib
- Create line plot with titleBasic Data AnalysisMatplotlib
- Sinus waveBasic Data AnalysisMatplotlib
- Change appearance of plot lineBasic Data AnalysisMatplotlib
- Create Line Plot With GridBasic Data AnalysisMatplotlib
- Population Growth Over YearsBasic Data AnalysisMatplotlib
- Linear Data with MarkersBasic Data AnalysisMatplotlib
- Exercise: Add Second Line to PlotBasic Data AnalysisMatplotlib
- Exercise: Multi-Line Plot with LegendBasic Data AnalysisMatplotlib
- Exercise: Multi-Line Plot with Random ValuesBasic Data AnalysisMatplotlib
- Exercise: Create Simple Scatter PlotBasic Data AnalysisMatplotlib
- Exercise: Create Smiley FaceBasic Data AnalysisMatplotlib
- Import pandas libraryBasic Data Analysispandas
- Load CSV fileBasic Data Analysispandas
- Get first 3 rows of pandas DataFrameBasic Data Analysispandas
- Get column from pandas DataFrameBasic Data Analysispandas
- Slice rows from pandas DataFrameBasic Data Analysispandas
- Slice rows and columns from pandas DataFrameBasic Data Analysispandas
- Filter rows and from pandas DataFrameBasic Data Analysispandas
- Filter rows based on multiple conditionsBasic Data Analysispandas
- Exercise: Get summary statisticsBasic Data Analysispandas
- Exercise: Get number of unique valuesBasic Data Analysispandas
- Create scatter plot with pandas columnsBasic Data Analysispandas
About Our Python Coding Challenges?
- Code directly in your browser: No need to install Python or any additional tools. Start solving challenges instantly.
- User-friendly and intuitive: Each challenge is designed with simplicity in mind. Pre-filled code gives you context, and you'll only need to adjust specific lines to solve the problem. Perfect for beginners.
- Get immediate feedback: Our browser-based Python environment runs code directly on your machine. You'll receive instant responses without waiting for a remote server.
- Progressive challenges for all skill levels: Whether you're just starting with beginner Python challenges or advancing your skills, our challenges grow with you.
- Build problem-solving confidence: Tackle real-world Python coding challenges step-by-step and watch your skills improve with each solved problem.
Frequently Asked Questions
What are Python programming challenges?
Python programming challenges are coding tasks designed to test and improve your Python skills. They often involve solving problems related to loops, functions, algorithms, or real-world scenarios. These challenges help you strengthen your understanding of Python and apply what you've learned in a practical way.
How can I improve my Python problem-solving skills?
To improve your Python problem-solving skills, practice is key. Start with beginner-friendly challenges to build confidence, and then progress to more complex problems. Focus on breaking down problems into smaller steps, writing clean code, and learning from mistakes. Pychallenger offers structured Python challenges that guide you through this process step by step.
Are these Python challenges suitable for beginners?
Absolutely! Our challenges are designed to be approachable for beginners while offering enough depth to keep advanced learners engaged. Start with basic topics like loops, conditionals, and functions, and gradually tackle more advanced Python programming challenges as you gain confidence.
Do these challenges include solutions?
Yes! Each challenge includes solutions that you can review after completing the task. This allows you to compare your approach, understand alternative methods, and improve your coding skills for future challenges.
How can I apply Python skills beyond challenges?
Once you've mastered Python challenges, you can take your skills further by exploring projects that let you build something practical. Check out our Python Projects page for guided, multi-step tasks that will help you applying Python in real-world scenarios. If you are done with that you can start building real applications in your own Python environment using an IDE like e.g. PyCharm.