Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling
 
PerlMonks  

Re: Re: Re: Finding largest common subset in lists?

by Dr. Mu (Hermit)
on Jun 06, 2003 at 05:03 UTC ( #263593=note: print w/replies, xml ) Need Help??


in reply to Re: Re: Finding largest common subset in lists?
in thread Finding largest common subset in lists?

This is still unclear. To which part(s) of the sentence does "but only deleting items before the first element of S or after the last element of S" refer? To the entire preceding part of the sentence, or only to the part after "deleting some items"? More to the point, given the following two sequences:
@seq1 = qw(a b c d e f g h); @seq2 = qw(a b c e f x g h);
is the answer  a b c  or  a b c e f ?

Replies are listed 'Best First'.
Re: Re: Re: Re: Finding largest common subset in lists?
by anjiro (Beadle) on Jun 09, 2003 at 04:57 UTC
    The answer is a b c. Getting a b c e f would involve deleting d from S for @seq1.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://263593]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others scrutinizing the Monastery: (4)
As of 2023-02-06 03:36 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    I prefer not to run the latest version of Perl because:







    Results (33 votes). Check out past polls.

    Notices?