48.1k views
2 votes
given a string s of characters, a subsequence of s, defined by the indices i 1, i 2, ..., i m , is said to be a repeated subsequence if you can find another sequence of indices j 1, j 2, ..., j m, such that s[i k]

1 Answer

5 votes

Answer:

= s[j k] for all 1 <= k <= m.

In other words, a repeated subsequence is a sequence of characters within the original string that appears in the same order at least twice. The indices i1, i2, ..., im refer to the positions of the characters in the original string that make up the repeated subsequence, and the indices j1, j2, ..., jm refer to the positions of the same characters in the second occurrence of the repeated subsequence.

User Mjordan
by
7.2k points