in reply to Re: Intersecting Two Strings
in thread Intersecting Two Strings

You forgot one corner case:
my $s1 = "1,0,CTGCCACCGCTGT"; my $s2 = "1,5,ACCG";
Apart from that, our solutions are identical-but your code is nicer I must admit ;)

Replies are listed 'Best First'.
Re^3: Intersecting Two Strings
by BrowserUk (Patriarch) on Aug 23, 2007 at 16:40 UTC
    You forgot one corner case:

    I did, didn't I :(

    I apologise for missing that you'd seen the same anomaly as I, amongst all the LCS posts.

    but your code is nicer I must admit ;)

    Actually, I think yours perfectly fine. Missing a couple of steps and tests, but fine. More importantly it works.


    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.