DoorDash interview question

find a qualified list from another list.