Connect x to itself, that’ll become xx.
Then search y in that.
The seraching of a string program is given at
doctorinterview.com/index.html/algorithmscoding/array-char-string/implement-strstr/
Refer Corman as it has wonderful explanation and it helps me to avoid copyright issues

Leave a Reply
You must be logged in to post a comment.