promptdojo_

Comprehensions and the wrong-layer bug — step 6 of 8

Write a list comprehension that takes the list prices = [12, 50, 8, 99, 30] and produces a new list containing only the prices over 15. Print the result.

Expected output:

[50, 99, 30]

full-screen editor opens — close anytime to keep reading.