Question: how to catch fruit flies?
Answer: Toss out any overripe fruit. Then, pour a cup of apple cider vinegar into a jar or small bowl.
Add a couple of drops of dish soap to the jar.
Place the trap in the area where you've seen the fruit flies, and wait for it to do its job.