This technical problem involves writing an SQL query that returns the top 3 most purchased products by customers. The example input and output are provided.
The solution above is optimal because it uses the ORDER BY and LIMIT clauses to sort the table by product_id in descending order and then limit the results to the top 3.
Evaluated at: 2022-10-31 02:36:36