Yet the gender caution reaches across divides — and into many workplaces.

Kathleen Raven, a science writer at Yale, considers herself to be progressive in many ways. But she does not have closed-door or out-of-office meetings alone with men, because she was previously sexually harassed. She also tries to avoid being too friendly, to ensure she doesn’t give the wrong impression.

“Women are taught to believe that we are equals while we’re growing up, and that’s not a good message,” said Ms. Raven, 34. “We have to make a lot of efforts to protect ourselves.”

Shelby Wilt, 22, of Gilbert, Ariz., said she and her boyfriend socialize alone with friends of the opposite sex. At work, though, it depends on the man. At the restaurant where she used to work, she would ask for conversations with certain men to take place in the kitchen, with others around. “It’s very much an instinctual call,” she said.

If they were above 65, Republican or very religious, respondents were slightly more likely to say people should take extra precaution around members of the opposite sex at work. They were less likely if they were young, students, not religious or registered as an independent.

“Organizations are so concerned with their legal liabilities, but nobody’s really focused on how to reduce harassment and at the same time teach men and women to have working relationships with the opposite sex,” said Kim Elsesser, author of “Sex and the Office: Women, Men and the Sex Partition That’s Dividing the Workplace.”