Problems

Practice coding problems

Build problem-solving habits with topic filters, difficulty levels, visible examples, and an online code workspace.

Follow a guided ladder

Choose a Python Foundations, coding practice, or PCEP review path and work through problems in order.

View ladders

Showing 10 of 30 problems

Clear filters
IntermediateSimulation

Attendance Streak

A string contains `P` for present and `A` for absent across several sessions. Find the longest consecutive run of `P`.

Open problem
IntermediateLists

Bus Route Check

Given a list of route stop names and a school name, print `YES` if the school appears in the route and `NO` otherwise.

Open problem
IntermediateGreedy

Market Change

Given item cost and cash paid in Jamaican dollars, output the minimum number of bills/coins for the change using denominations 5000, 1000, 500, 100, 50, 20, 10, 5, and 1.

Open problem
IntermediateSorting

Mentor Pairing

Given skill scores for students, sort them and print the difference between the highest and lowest score.

Open problem
IntermediateFunctions

Practice Groups

Each mentor group can hold `k` students. Given `n` students, print the minimum number of groups needed.

Open problem
IntermediateDictionaries

Project Tags

Given `n` project tags and one target tag, count how many times the target appears.

Open problem
IntermediatePrefix Sums

Workshop Capacity

Given attendance counts for sessions and a range `l` to `r`, print the total attendance in that inclusive range.

Open problem