Suffix array 1

A.Sandy card

  After all of the series the difference up request $ $ height, converted to binary answer whether there is a contiguous segment such that the interval of $ $ height greater than half of the entire value and covers all the strings.

B. meow named on the planet

  This approach is very much the question. . . The first automatic machine with water AC too violent, decadent way a solution to a problem, then and now do know one side of the label. .

  More convenient approach is Mo + suffix array team, all strung together for the beginning of each named after the binary string determined period interval, this interval so that the whole is greater than $ $ height equal to the string length named after the number of colors can be converted into the interval problem, in many ways, but the way Mo team can maintain at the same time the number of colors of the second question, it is better to play.

C. strings

  $ Height $ length to take min makes us very unhappy, so half of the answers to remove the restriction length, and then still two separated period included $ rk [c] $ continuum, making $ height $ greater than equal to half the length of the Chairman of the tree verify the current dichotomy is there a range of $ rk $ to within this range.

D. Differences

  $ $ Height determined array, each stack get monotonous $ $ height as the minimum interval, the answer can be accumulated.

E. similar substring

  Conclusion: the essence of a rank i is a suffix to provide different number of sub-string: $ n-sa [i] -height [i] + 1 $, and these increments in accordance with the ranking substring suffix ranking. It should not be difficult to understand.

  Can then be separated position of the two sub-strings $ k $, $ LCP request $, $ $ LCS would be finished.

F. tasting General Assembly

  And a difference almost the same hair. . . Is more than a maximum weight, $ ST $ table check would be finished.

Guess you like

Origin www.cnblogs.com/hzoi-cbx/p/12088033.html