For those who want guidance/algo


Step 1:sort the array in alphabetical order.
step2: compare elements of first and last string till you got the first unmatched element.
Step 3: if they are same, append them in a new string.
the new string is the required string
happy coding!!


I think no need of sorting…!!!