Avoid "Spock's Brain," "The Omega Glory," "Turnabout Intruder," and "The Way to Eden" in the original series. (Spock's Brain and Way to Eden are generally agreed to be the absolute worst ones)
If you watch Voyager, then absolutely avoid The Fight and Threshold. Also avoid Spiritfolk, Fair Haven, and Tattoo (explains Chakotay's tattoo, but it's pretty offensive by today's standards *it was offensive even by the standards of the day*. FYI, the actor for Chakotay is a Mestizo who plays a *presumably Peruvian* indigenous person, and it's a lot worse than it sounds hint: Peru is where the Nazca Lines are.)
For TNG,
absolutely avoid
Shades of Gray and Sub Rosa. Most people including me agree that Masks, The Child, and Man of the People suck. Code of Honor is really bad as well; its only redeeming feature is getting to see Tasha in a duel (if you're a big Tasha fan like I am)