cf/mirror

Division + LCP (hard version)

CF
1968G22200· master3s256 MB⌨ stdin/stdout

Examples

Sample 1of 1multi-test • hover to link
Input
7
3 1 3
aba
3 2 3
aaa
7 1 5
abacaba
9 1 6
abababcab
10 1 10
aaaaaaawac
9 1 9
abafababa
7 2 7
vvzvvvv
Output
3 1 0
1 1
7 3 1 1 0
9 2 2 2 0 0
10 3 2 1 1 1 1 1 0 0
9 3 2 1 1 0 0 0 0
2 2 1 1 1 0
1968G2.cpp
loading editor…
Ln 11·137 BGNU C++20 (64)