# HG changeset patch
# User Frederic Chapoton <chapoton at math.univlyon1.fr>
# Date 1362309515 3600
# Node ID a442346e37c37dcddf8d6f17e695dd3cb749eec3
# Parent 313888c7b5c80ed64ea317dc5d6065c5be9d0b45
trac #14121 add a test
diff git a/sage/combinat/words/shuffle_product.py b/sage/combinat/words/shuffle_product.py
a

b

class ShuffleProduct_w1w2(CombinatorialC 
62  62  True 
63  63  sage: w in S 
64  64  False 
 65  
 66  We check that :trac:`14121` is solved:: 
 67  
 68  sage: w = W('ab') 
 69  sage: x = W('ac') 
 70  sage: x*w in w.shuffle(x) 
 71  True 
65  72  """ 
66  73  from sage.combinat.words.word import Word 
67  74  if not isinstance(x, Word_class): 
… 
… 
class ShuffleProduct_w1w2(CombinatorialC 
85  92  else: 
86  93  return False 
87  94  return len(wx) == 0 
88   
 95  
89  96  def cardinality(self): 
90  97  """ 
91  98  Returns the number of words in the shuffle product 