module Diff::LCS
def lcs(other, &block) #:yields self[i] if there are matched subsequences:
O.new('a').eql?(O.new('a')) == true
identically for key purposes. That is:
implement Object#eql? in a way that two identical values compare
can be used as a key in a Hash, which typically means that the objects must
A note when using objects: Diff::LCS only works properly when each object
lcs = seq1.lcs(seq2)
+self+ and +other+. See Diff::LCS#lcs.
Returns an Array containing the longest common subsequence(s) between
rubocop:disable Style/Documentation
def lcs(other, &block) #:yields self[i] if there are matched subsequences: Diff::LCS.lcs(self, other, &block) end