Пожалуйста, прочтите новое правило об ограничении использования AI-инструментов. ×

Блог пользователя uvzqra490

Автор uvzqra490, история, 8 лет назад, По-английски

Given a suffix array we have to calculate the lexicographical smallest string which has the same suffix array . Can someone please give some hint how to solve this problem ?

  • Проголосовать: нравится
  • +25
  • Проголосовать: не нравится

»
8 лет назад, # |
  Проголосовать: нравится +33 Проголосовать: не нравится

Assume that x y — two consecutive suffices in suffix array. First of all, we know that s[x] <= s[y]. Moreover, (s[x] < s[y]) or ((s[x] = s[y]) and (s[x+1:] < s[y+1:])). Do we have a way to compare two suffices?

I think it is big enough hint to solve the problem, but if you still don't understand how after 20-30 minutes thinking, I can explain solution in PM.