null
...
LeetCode - The World's Leading Online Programming Learning Platform
Level up your coding skills and quickly land a job. This is the best place to expand your knowledge and get prepared for your next interview.leetcode.com
yeah you need to sort them and then pair-wise compare them. you can shortcut by discarding anything shorter than your running longest-common-value or anything where sub-strings of that length are not equal. i have an accepted solution on leet and i'll post it here in a bit. in c++. i don't know rust yet.