← Bloomberg questions
CodingReported in a candidate post, Jun 2020

Compare two strings under a custom alphabet with 1-2 letter symbols

Filed under Bloomberg

A new language has an alphabet given as an ordered list of symbols, each one or two letters long (for example [w, b, aa, c]). Write compare(alphabet, a, b) that returns -1, 0 or 1 depending on whether…

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 Bloomberg questions

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