Recyclable and Low Fat Products
products has columns id, low_fat and recyclable, where the last two are "Y" or "N". Return a list of the ids of products that are both low fat and recyclable, in the order they appear.
Example 1
products {"id":[1,2,3],"low_fat":["Y","Y","N"],"recyclable":["N","Y","Y"]}
returns [2]
Only product 2 has Y in both.
Constraints
- The result may be an empty list
Write it in your browser, against the clock. The model solution, stepped through line by line, comes after.