Suffix Tree - Application 3 - Longest Common Substring
hard
Given 2 strings, print the length of longest common substring and print the start points of the same
Constraints
|S1|,|S2| <= 10^5
Format
Input
Input consists of 2 lines, each containing a string.
Output
Print the length of longest common substring, and all the start points of the same in the next line
Example
Sample Input
pepcoder
xyzcoderpep
Sample Output
5
3 12