We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
In case anyone also needs this piece of information:
A string s which is the prefix of a string t can appear aftert in the list.
Meaning in the given example:
3abcddbacab
The output should be:
BADSETab
I know it was described in the problem already, but I completely missed the idea that the prefix string could appear after in the array. Between revising my code and trying to replicate the logic I probably spent more time than coding and thinking about the solution, all because a information was "missing". So, I hope this helps
someone with the same misconception.
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
No Prefix Set
You are viewing a single comment's thread. Return to all comments →
In case anyone also needs this piece of information: A string
s
which is the prefix of a stringt
can appear aftert
in the list.Meaning in the given example:
The output should be:
I know it was described in the problem already, but I completely missed the idea that the prefix string could appear after in the array. Between revising my code and trying to replicate the logic I probably spent more time than coding and thinking about the solution, all because a information was "missing". So, I hope this helps someone with the same misconception.