#include<iostream> #include<cstring> using namespace std; typedef unsigned long long int unlarge; const int maxn=1e5+5; unlarge heap[maxn],p[maxn]; int x=131; char ch[maxn]; unlarge get(int left,int right) { return heap[right]-heap[left-1]*p[right-left+1]; } void tohash(char *ch,int ...