👩💻 Join our community of thousands of amazing developers!
3076. Shortest Uncommon Substring in an Array You are given an array arr of size n consisting of non-empty strings. Find a string array answer of size n such that: answer[i] is the shortest substring of arr[i] that does not occur as a substring in any other string in arr. If multiple such substrings exist, answer[i] should be the lexicographically smallest. And if no such substring exists, answer[i] should be an empty string. Return the array answer. ...