Reference solution
The shape we check against. Compare it with your query: the set of rows matters, the formatting does not.
SELECT category, MAX(price) AS max_price FROM products GROUP BY category ORDER BY max_price DESC;
For each product category return the category and the highest price in it, aliased as max_price. Sort by max_price descending.
hint ladder
Write a query with WITH … AS (…) blocks, then inspect each intermediate table before the final SELECT.
Run your code to see its output, or check your solution to grade it.
Reference solution
The shape we check against. Compare it with your query: the set of rows matters, the formatting does not.
SELECT category, MAX(price) AS max_price FROM products GROUP BY category ORDER BY max_price DESC;
Code is blurred until you solve this problem — the reasoning stays readable.