This idiom is very common in any context involving strategy or advice. It is considered thoughtful and wise.
Business and Work: In a performance review, a manager might say, “你的分析能力很强,但口头报告是弱项。我们应该扬长避短,让你多负责数据方面的工作。” (Your analytical skills are strong, but oral reports are a weak point. We should play to your strengths and avoid your weaknesses, letting you take more responsibility for the data-related work.)
Education and Study: A teacher might advise a student preparing for the Gaokao (college entrance exam) to 扬长避短 by spending more time on their best subjects to secure high scores, rather than trying to fix their worst subject at the last minute.
Personal Relationships: When giving a friend advice on their career, you might suggest they choose a path that allows them to 扬长避短. For someone who is introverted but highly creative, a career in graphic design would be a better fit than a sales role.
Formality: As a chengyu, it lends a sense of formality and wisdom to a conversation. It's not slang, but it's understood by everyone and used frequently in writing, formal speeches, and serious discussions.