Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.programming > #3107

Re: Modified Levenshtein Distance Algorithm

Newsgroups comp.programming
Date 2013-02-25 07:24 -0800
References <e02f014f-ccf3-410c-a6bf-93ca7fa212c1@googlegroups.com> <LdWdnYFTW4ajtrrMnZ2dnUVZ8nSdnZ2d@bt.com> <512b36dc$0$6935$e4fe514c@news2.news.xs4all.nl> <512b37b9$0$6990$e4fe514c@news2.news.xs4all.nl>
Message-ID <b227113d-aef7-44d7-ab01-e5fc7343b3d3@googlegroups.com> (permalink)
Subject Re: Modified Levenshtein Distance Algorithm
From bob <bob@coolfone.comze.com>

Show all headers | View raw


On Monday, February 25, 2013 4:06:49 AM UTC-6, Jongware wrote:
> On 25-Feb-13 11:03 AM, Jongware wrote:
> 
> 
> 
> Oops. Forgot about JS' string handling. Change this line
> 
> 
> 
> >        if (X[i] == Y[j])
> 
> 
> 
> to this
> 
> 
> 
>     if (X[i-1] == Y[j-1])
> 
> 
> 
> and then you get a longest common subsequence value of 2 for "BAT/CAT", 
> 
> which sounds a bit more logical.
> 
> 
> 
> [Jw]

The LCS of those strings is clearly two as it is "AT".

What's not clear is if that's what the OP is really looking for.

Back to comp.programming | Previous | Next — Previous in thread | Find similar | Unroll thread


Thread

Modified Levenshtein Distance Algorithm billmann <willmann817@gmail.com> - 2013-02-20 15:55 -0800
  Re: Modified Levenshtein Distance Algorithm bob <bob@coolfone.comze.com> - 2013-02-21 11:06 -0800
    Re: Modified Levenshtein Distance Algorithm billmann <willmann817@gmail.com> - 2013-02-21 18:51 -0800
      Re: Modified Levenshtein Distance Algorithm bob <bob@coolfone.comze.com> - 2013-02-22 07:29 -0800
  Re: Modified Levenshtein Distance Algorithm "Chris Uppal" <chris.uppal@metagnostic.REMOVE-THIS.org> - 2013-02-22 08:22 +0000
    Re: Modified Levenshtein Distance Algorithm Jongware <jongware@no-spam.plz> - 2013-02-25 11:03 +0100
      Re: Modified Levenshtein Distance Algorithm Jongware <jongware@no-spam.plz> - 2013-02-25 11:06 +0100
        Re: Modified Levenshtein Distance Algorithm bob <bob@coolfone.comze.com> - 2013-02-25 07:24 -0800

csiph-web