Back to problems

Concatenated Words with All Decompositions

Algorithm · Amazon · Hard

Problem: List Every Decomposition of Concatenated Words You receive a collection of distinct lowercase strings called words. A string is considered concatenated when it can be constructed by joining two or more entries from that collection in sequence. Identify every such string and print all valid ways to split it into dictionary words. Rules Each piece in a decomposition must appear in words. A word may be selected more than once within the same decomposition. A word does…

Checking your access…