『Forensic Examination 后缀自动机 线段树合并』
CF666E Forensic Examination Description 给你一个串 \(S\) 以及一个字符串数组 \(T[1..m]\) , \(q\) 次询问,每次问 \(S\) 的子串 \(S[p_l..p_r]\) 在 \(T[l..r]\) 中的哪个串里的出现次数最多,并输出出现次数。 如有多解输出最靠前的那一个。 Input Format The first line contains the string $ s $ ( $ 1<=|s|<=5·10^{5} $ ) — the Absolutely Inadmissible Swearword. The string $ s $ consists of only lowercase English letters. The second line contains the only integer $ m $ ( $ 1<=m<=5·10^{4} $ ) — the number of texts of leaflets for expertise. Each of the next $ m $ lines contains the only string $ t_{i} $ — the text of the $ i $ -th leaflet. The sum of lengths of all