← Morgan Stanley questions
CodingReported in a candidate post, Jul 2020

Group strings by set of characters and sort lexicographically

Filed under Morgan Stanley

Given a list of strings, group them based on the unique set of characters they contain. Sort each group lexicographically and print each group on a separate line.

You've read your 3 free write-ups

Sign up free to keep reading. Your account opens the first 10 questions of every company.

Related Morgan Stanley questions

Collected from public candidate posts and coding forums. Updated Nov 2026.