in reply to Re^3: True Brute Force Longest Common Sub Sequence
in thread True Brute Force Longest Common Sub Sequence

"Sequence" means that you cannot skip characters in your string.

What you are describing would be a contiguous sequence. Otherwise known as a 'substring'. Skipping characters is permitted, it is their relative positions that makes it a sequence.

Contrast LC subsequence with LC substring.

For the subsequence problem, the characters in the solution must


Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
"Science is about questioning the status quo. Questioning authority".
In the absence of evidence, opinion is indistinguishable from prejudice.
"Too many [] have been sedated by an oppressive environment of political correctness and risk aversion."
  • Comment on Re^4: True Brute Force Longest Common Sub Sequence

Replies are listed 'Best First'.
Re^5: True Brute Force Longest Common Sub Sequence
by CountZero (Bishop) on Nov 25, 2007 at 13:24 UTC
    Thank you!

    Not a day passes or we learn new things in our Monastery.

    CountZero

    A program should be light and agile, its subroutines connected like a string of pearls. The spirit and intent of the program should be retained throughout. There should be neither too little or too much, neither needless loops nor useless variables, neither lack of structure nor overwhelming rigidity." - The Tao of Programming, 4.1 - Geoffrey James