Coding Challenges

Sharpen Your Skills with Coding Challenges

Practice programming problems, test your solutions, and learn from the reference answer. New challenges added regularly.

#001Easy
Python

Reverse a String

Write a function that reverses a string without using the built-in reverse() method. For example, 'hello' should return 'olleh'.

Category: String Manipulation

#002Easy
Python

FizzBuzz

Write a function that prints numbers 1 to n. For multiples of 3, print 'Fizz' instead. For multiples of 5, print 'Buzz'. For multiples of both, print 'FizzBuzz'.

Category: Algorithms

#003Easy
JavaScript

Palindrome Checker

Write a function that checks if a string is a palindrome (reads the same forwards and backwards). Ignore case and spaces.

Category: String Manipulation

#004Medium
Python

Fibonacci Sequence

Write a function that returns the nth Fibonacci number. The sequence starts: 0, 1, 1, 2, 3, 5, 8, 13, 21...

Category: Algorithms

#005Easy
Python

Reverse a String

Write a function that takes a string and returns it reversed. For example, 'hello' should return 'olleh'.

Category: String Manipulation

#006Medium
Python

Find Duplicate Numbers

Write a function that takes a list of numbers and returns a list of all numbers that appear more than once. Each duplicate should appear only once in the result.

Category: Algorithms

#007Easy
JavaScript

Build a Calculator

Write a calculator function that takes two numbers and an operator (+, -, *, /) and returns the result. Handle division by zero.

Category: Utilities

#008Medium
JavaScript

Parse and Extract from JSON

Write a function that takes a JSON string representing a list of users (each with name and email) and returns an array of just the email addresses.

Category: Data Structures

#009Hard
JavaScript

Build an API Request Function

Write an async function that fetches user data from an API by ID, handles errors, and returns null if the user is not found or the request fails.

Category: Utilities

Ready to solve?

Open a challenge, write your solution, and test it with AI assistance.