Check if given string can be split into two substrings X and Y
Given a string str. The task is to check whether this string can be splitted into two strings X and Y such that Y is a substring of X X + Y = str (Here, X+Y means X and Y are concatenated) Examples : Input: pleaselea Output: Yes str = “please” + “lea”, Here “lea” is a substring… Read More »