Problem Statement
Note to plugin users: there is an image in this problem statement. Please view the statement in the applet to see the image
There is a collection of multi-colored stamp pads at the local craft store. Each pad has 5 colors on it, arranged as pie wedges (see picture). The wedges can be switched out with other wedges, so you can create the ultimate blend of colors for your favorite stamp. You have a wish list of certain colors, but each pad set is expensive, so you want to minimize the cost. Given the colors of each pad and the colors you want, return the minimum number of pad sets that you must buy in order to get the right colors.
Here is an example of a stamp pad that you can buy:
You will be given a
"<color> <color> <color> <color> <color>"
Each <color> will be a
"yellow red purple blue cyan"
Each element of wishlist is a color that you wish to own. Your method should return the minimum number of pads you must buy to get all the colors in wishlist, or -1 if it is not possible to do.
Definition
- Class:
- StampPads
- Method:
- bestCombo
- Parameters:
- String[], String[]
- Returns:
- int
- Method signature:
- int bestCombo(String[] pads, String[] wishlist)
- (be sure your method is public)
Constraints
- pads will have between 1 and 20 elements, inclusive.
- Each element in pads will have between 9 and 50 characters, inclusive.
- Each element in pads will consist of exactly 5 color names separated by single spaces.
- Each color name in pads will have between 1 and 15 characters, inclusive, and will consist of only lowercase letters 'a'-'z', inclusive.
- There will be no repeated color names in a single element of pads
- wishlist will have between 1 and 25 elements, inclusive.
- Each element of wishlist will have between 1 and 15 characters, inclusive, and will consist of only lowercase letters 'a'-'z', inclusive.
- There will be no repeated elements in wishlist.
Examples
{"a b c d e", "b c d e f", "c d e f g", "d e f g h", "e f g h i", "f g h i j", "g h i j k", "h i j k l", "i j k l m", "j k l m n", "k l m n o", "l m n o p", "m n o p q", "n o p q r", "o p q r s", "p q r s t", "q r s t a", "r s t a b", "s t a b c", "t a b c d"}
{"a", "b", "c", "d", "e", "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q", "r", "s", "t"}
Returns: 4
{"yellow red purple blue cyan", "red green orange magenta yellow", "brown black orange yellow tan"}
{"orange", "yellow", "red", "blue", "magenta", "tan"}
Returns: 3
We can only get blue from the first pad, magenta from the second pad, and tan from the last. Therefore, all three must be purchased.
{"yellow red purple blue cyan", "red green orange magenta yellow", "brown black orange yellow tan"}
{"orange", "yellow", "red", "blue", "tan"}
Returns: 2
Although we can get orange and yellow from the second pad, we can get orange, yellow, and tan from the last, so the second is unnecessary.
{"yellow black blue green red", "yellow brown cyan magenta tan", "black grey fire maroon silver", "blue white neon tangerine rust", "green orange soot turquoise mint", "red cream opal chrome sky"}
{"yellow", "black", "blue", "green", "red", "brown", "grey", "white", "orange", "cream"}
Returns: 5
Although you can buy the first pad and get 5 colors on the wishlist, you still must buy the other 5 to get the rest of the colors. However, if you just buy the last 5 pads, you get all the colors.
{"red green orange magenta yellow"}
{"silver"}
Returns: -1
The single stamp pad available does not have silver, so the wishlist is impossible to fulfill.
{"d v h e o", "j h e k c", "b l h m k", "x g z h y", "z y d l e", "d u b g v", "t m d n c", "f u x p j", "v w c i x", "j f y k v", "u p q k v", "t k p m n", "l t p d b"}
{"b", "i", "j", "u", "n", "l", "m", "y", "v", "w", "t", "k", "e", "x"}
Returns: 5
{"h a b f t", "h e b l z", "a c q k o", "r z e s c", "r n k j o", "n o f b s", "l i r f d", "d r i e s", "p h u c v", "r n y o c", "d s c x n", "z k q d b", "k j h l u", "d g w f x", "t u w m y"}
{"h", "r", "i", "p", "y", "u", "s", "x", "c", "z", "n", "m", "k", "d", "e", "w", "q", "j", "b", "g"}
Returns: 6
{"a j b u c", "q y j l k", "z i m d o", "q v t w u", "q b j p f", "b l z d s", "g a f n q", "z e y s p", "n y x c e", "d j y x g"}
{"u", "z", "s", "a", "b", "c", "d", "j", "e", "w", "f", "m", "k", "g"}
Returns: 6
{"g u a w d", "a u l x c", "o a m w l", "w b x k u", "u g x s t", "p a u i j", "l r p u v", "v i l e u", "d i r o p", "m b u k l", "c i h v t", "l y a h n", "n o g p v", "e r s a n", "i t r q c"}
{"e", "i", "n", "u", "v", "l", "w", "y", "g", "j", "m", "d", "h", "o", "k", "t", "p", "q", "r", "x", "a"}
Returns: 7
{"r v z k a", "b x h p i", "k x s i z", "y g q d p", "z r t i l", "y d e u k", "b p i l v", "l j p g x", "i s n b u", "u t y s r", "i z g q v", "q r y d n", "i c z b u", "h a j u v"}
{"l", "p", "n", "e", "q", "a", "b", "g", "v", "r", "h", "i"}
Returns: 5
{"t u e n l", "r g e s t", "w v l y f", "t q z i y", "d s y p u", "a t b k w", "r u o b q", "j v f k n", "m r x s u", "n h r s f", "z a m q b", "b y o c w", "h l t j m", "v x y z n"}
{"m", "q", "z", "b", "x", "e", "a", "h", "n", "d", "i", "o", "p", "r", "c", "f"}
Returns: 7
{"k f p s t", "h u f m d", "r w o t p", "k d m p w", "g b f x a", "p e k y h"}
{"e", "a", "y", "h", "f", "b", "d", "r", "k", "g", "m", "w", "s", "o", "u", "t"}
Returns: 5
{"q a b u e", "z d y e i", "c m u q i", "h v r s f", "b r z k q", "u e k i y", "m x a c d", "v s m w t"}
{"c", "t", "d", "y", "b", "r", "x", "z", "e", "u", "q"}
Returns: 4
{"q s r a p", "h z v i j", "e m f n t", "k s t e j", "a e v p u", "r h q n e", "q m o r j", "b g a c p", "z b u w c", "n o z m j", "x p j s o", "a e n b j", "n j q v b", "e o q m y", "k q v i u", "w y t b d"}
{"p", "n", "x", "w", "e", "o"}
Returns: 3
{"a u p r b", "v w x m y"}
{"m", "w"}
Returns: 1
{"h q i j x", "p t f a q", "g k z a l", "a l c d g", "k l m y e", "r q m g c", "p h w v q", "y u w x g", "d v a b n", "a z f g b", "e w m x r", "d g h f v", "v g l j k", "g s n v a", "h e c d n"}
{"q", "r", "w", "z", "g", "v", "s", "x", "h", "m", "t", "u", "o", "i", "f", "y", "a", "b", "c", "n", "p"}
Returns: -1
{"m e n z c", "v y d b o", "x g e n p"}
{"x", "m", "d", "g", "v", "y", "c", "z", "n", "b", "e", "o"}
Returns: 3
{"d n e h y", "x h s u v", "c d e h l", "l v o s e", "j e g h k", "d k i a b", "r c j s l", "x t j m f", "p w j f r", "b q v t u", "p a u v b"}
{"w", "e", "j", "f", "x", "m", "y", "u", "d"}
Returns: 4
{"e j c v f"}
{"c", "v", "j"}
Returns: 1
{"z q r x a", "o l y u j", "z g w e h", "b r z t g", "n x a f d", "i d a q w"}
{"o", "y", "g", "z", "f", "l", "t", "n", "w", "d", "e", "u", "x", "b", "h", "i", "a", "j", "q", "r"}
Returns: 5
{"e u b f m", "f p u l c", "b x d c v", "a l z d s", "a x j s b", "t s l h y", "p g n h i"}
{"s", "n", "e", "c", "x", "l", "j", "h", "y", "a", "m"}
Returns: 5
{"c d j z b", "h i o d f", "d e u z c", "q x r n k", "q n d f z", "b z k x c", "q s u e g", "b l d s w", "s o u p q"}
{"n", "j", "z", "w", "m", "o", "b", "p", "k", "l", "s", "q", "c"}
Returns: -1
{"d j n z e", "o i e y k", "l g r y v", "j o w p y", "o y e t w", "n u c f t", "j m q n h", "d y s c z", "s a l v r", "k j w c f", "e z u w v"}
{"k", "z", "y", "m", "s", "l", "n", "o", "p", "i"}
Returns: 5
{"g b e f z", "k s p q t", "m x w g f", "a d o r b", "o h l f a", "b r w i j", "e a r l u", "d y p g i", "z q b s o", "z n m a o", "x t g u e", "c p w a q"}
{"c", "h", "d", "t", "l", "n", "o", "m", "u", "p", "q"}
Returns: 5
{"g o r a s", "k m a s j", "y f i v z", "r b j a c"}
{"z", "m", "b", "c", "f", "a", "i", "o", "y", "k", "r"}
Returns: 4
{"d j v h k", "b x e h m", "z t q n e", "c d r s z", "j b o i q", "t r s u b", "x r v e m", "b i p x q"}
{"z", "h"}
Returns: 2
{"o g l f a", "s f e g a"}
{"l", "a", "e", "f"}
Returns: 2
{"j o y t k", "u j e f g"}
{"j", "o"}
Returns: 1
{"f d w t e", "z h a b c", "g a c b k", "t k l d n", "f v k n o"}
{"n", "t", "k", "a", "b", "o", "c", "v", "w", "z", "g", "h"}
Returns: 4
{"u i j n q", "e x o w h", "y p n b g", "k e l g y", "p b c d r"}
{"d", "j", "o", "n", "p", "k", "i", "c", "u", "l", "q", "w", "r", "e", "g", "h", "b", "x", "y"}
Returns: 4
{"p a j q b", "t w z j k", "j h n l c", "z e a k p", "n o q z a", "u p j s c", "w u r k l", "q v c l w", "l j p g h", "o c d e b", "g z m i a", "p n l m u"}
{"a", "v", "z", "m", "w", "n", "k", "o", "b", "s", "c", "g", "h", "r", "p", "i", "t"}
Returns: 7
{"f p g i l", "k z o x f", "w h c g m"}
{"k", "w", "c", "x", "l", "i", "z", "f", "g", "h", "m", "o", "p"}
Returns: 3
{"m k n c q", "t b c o j", "l v u d y", "x l i q o", "u o m g z", "k n s e l", "w y x t u", "r e d n y", "a u x o b", "y q h c e", "p v l g i", "t j o u i", "b q e a i", "v a o g s", "p o i j l", "b o k c t", "w z n e q", "r p a v x", "l t q j g", "r n k m o"}
{"a", "d", "f", "g", "b", "h", "j", "t", "c", "i", "e", "s"}
Returns: -1
{"j m p e l", "f h d r v", "m y n o z", "l u j f r", "f m v o w", "a q v l j", "p q d m o", "u v o l j", "l m n o f", "p r i v q", "f l h w y", "y u a q r", "n s b c o", "z x p u e", "y v w z f", "s k f l b", "u r s h y"}
{"q", "w", "y", "k", "r", "s", "x"}
Returns: 4
{"b a k x t", "l c e q x", "u z k v n", "g e s y f", "c g t s d", "d r t l m", "x s i l n", "f j t g u", "z t s n a", "t g u r o"}
{"v", "u", "z", "g", "d", "b", "r", "x", "y", "c", "j", "e"}
Returns: 6
{"v b u x k", "l k e a z", "g w q i v", "d s p k j", "z l n x u", "n l b o q", "g t s o f", "z m a k d", "n t w i u", "a g v m n", "f a g b z", "i a s v h", "d q r i h", "g b u v a", "g m e w o", "m b v c g", "p x e u v", "w t k q u", "s i y c n"}
{"k", "w", "b", "l", "j", "c", "f", "m", "y", "o", "n", "v", "p", "q", "z", "a", "r", "g", "s", "x", "i", "t", "h", "d"}
Returns: 7
{"l m p y x", "e r d m y", "b l e w a", "a b c f s", "f q t y l", "v q b g y"}
{"x", "c", "s", "y", "l"}
Returns: 2
{"b q n f o", "z j h a m", "w i n k v", "f p y q e", "c d q r h", "q r t l u", "p c b l z", "b p m e n", "y e f a g", "u t p e q", "c l y s z", "e h l m n", "b t a n d", "i d z w j", "z o u p b", "h z s o i"}
{"t", "j", "u", "v", "w", "r", "m", "y", "z", "b", "k", "l", "a", "c", "n", "d", "e", "f", "g", "q", "h", "i", "o", "p", "s"}
Returns: 7
{"b w s n p", "w y x d z", "e w o f z", "u q d p e", "q y t x d", "c x y o h", "b k y j p", "q h i t x", "w j m d p", "s j q a k", "b w z m u", "p o h n e", "i b c p l", "r o v b u", "i h s j k", "p b a g f", "d y g t c"}
{"u", "i", "m", "j", "q", "f", "k"}
Returns: 4
{"u s x k d", "n b j o t", "w l v d a", "s r t e k", "y l x u z", "r k f p g", "o z f a e", "k e h c f", "d e t h a", "l g v m w", "s u m g w", "e w y v o", "e s m r p", "c d e x j", "n o j l x"}
{"r", "k", "t"}
Returns: 1
{"y c z a u", "g m q b p", "m j g p l", "x g h f i", "s q f t y", "t s j e r"}
{"m", "y", "u", "h", "x", "q", "i", "j", "l", "p", "c", "t"}
Returns: 4
{"u z a k r", "l g h x y", "h c n g i", "w m d x h", "h s o i j", "c y g h t", "n g p a e", "q m r s t", "i s l g j", "h j i p f", "g t o h b", "m c f s d", "b u c v r", "k a t x l", "a z s k o"}
{"w", "q", "f"}
Returns: 3
{"m g j u f", "l p q d u", "f t r v b", "b p a n h", "d r b c x", "r m k v g", "x z o k n", "u h b j v", "x g t a j", "m o d r u", "w i e n x", "s z t c u", "e j x y q", "g d m i e", "u e w g v", "v u n d a", "u h m r q", "k h i w f", "t b p h a", "s t y c z"}
{"x", "r", "e", "c", "v", "n", "o", "w", "y"}
Returns: 4
{"s j g v u", "v o u i w", "z j r g s", "l f z g d", "j m u z o", "s v n y p", "q b z d y", "t w k p u", "i v a u z", "i f e p b", "v u h z k", "f k i e l", "v h k r e", "e f m b n", "b r x u h", "p c x y v", "d y i h j", "i x b j f", "m p j i n", "w g k f z"}
{"t", "c", "u", "o", "p", "l", "z", "i", "h", "v", "g", "k", "s", "b", "j", "m", "r", "w", "n", "f", "d", "x", "a"}
Returns: 7
{"y p k q r", "z x m c h", "l n z h u"}
{"n", "x", "z", "k", "l", "y", "m", "c", "h"}
Returns: 3
{"w y g d o", "k w z r l", "u v p k c", "c t q r s", "p c m x t", "y n d z m", "f g h n a", "v n w s a"}
{"s", "c", "y", "z", "u", "g"}
Returns: 4
{"o z n p m", "c q l m d", "m k d i n", "f v e k j", "h r y d q", "f t q y z", "v p o w q", "v y x q k", "n g u o x", "v o p k l"}
{"k", "x", "t", "d", "q", "u", "z", "v", "l", "m", "w", "y", "r", "i", "c", "e", "f", "n", "g", "j", "h", "o"}
Returns: 7
{"y x l e g", "p b z a q", "l k f q r", "w t r f h", "z e m j p", "f g b z k", "y x d m s", "a y z v m", "z x l f n", "q s j y e", "b h l w r"}
{"b", "v", "y", "z", "n", "t", "p", "l", "x", "q", "d", "a"}
Returns: 5
{"o j i z v", "c s p n q", "q c p u x", "n o l h u", "p f g e t", "r x y a h", "v k w i n", "l v y t z", "u j i v k"}
{"f", "e", "c", "z", "j", "t", "p", "u"}
Returns: 3
{"l q a t u", "c r w k t", "k w p j o", "n r i e t"}
{"t", "a", "n", "q", "i", "o", "u", "w", "j", "e", "k", "r", "c"}
Returns: 4
{"x y l b q", "c g a y q", "w y a p h", "z r y o a", "c f u q r", "d e i g n", "r j a s t", "d x g u c", "k q g y a", "x c n d o"}
{"t", "b", "c", "n", "l", "k", "w", "j", "o", "y", "g", "p", "q", "m", "i", "h", "z"}
Returns: -1
{"c h q i j", "u m j p q", "b p r f c", "f d b q s", "a e s t b", "f s m u v", "s y m n i", "g h i w b", "n u e l v", "m s t g q", "e b r f t", "f g h r n", "o v l g c", "v h d k y"}
{"s", "i", "f", "t", "e", "c", "n", "l", "u", "j"}
Returns: 4
{"r b h w g", "b e z p d", "f s u x r", "p o s b a", "t f q c g", "t n z u k", "e q v f w", "n d q v t", "y k u h p"}
{"q", "i"}
Returns: -1
{"j p k c l", "f h r x g", "c p a h i", "u l b v i", "m p i z h", "h x r s j", "p v b w n", "l j m s w", "k l b c f", "g z l j k", "z y t q l", "q l e s z", "c h m y v"}
{"e", "m", "g", "w", "p", "r", "n", "d", "q", "s", "i", "f", "x", "b", "v", "t", "u", "a"}
Returns: -1
{"p z g r u", "d o e t w", "s p g o t", "i p h c s", "d n g s h", "h v s x a"}
{"c", "d", "z", "n", "v", "a"}
Returns: 4
{"h q l p y", "f t e u m", "b s c d a", "d y u t v", "r e c f g", "r l e k m", "p z j x d", "n c u k x", "g t q l v", "w u l h e", "r o y s t", "b i t v c", "q i z g f", "n r g z a", "u j q s p", "e i l r h", "t x f w m", "n e s d o", "f l z x a", "l u a w d"}
{"p", "a", "q", "o", "u", "h", "i", "v", "j", "b", "k", "x", "r", "s", "y", "t", "l", "m", "n"}
Returns: 6
{"w t k p j", "b g c k w", "i j x t a", "a o z v u", "t y g b n", "m v u y g", "c x y h d", "s n c i l", "l g b u c", "y n g u z", "x y k m e", "u f a k x", "y k v r a", "v m f q x", "s p o b z", "d w y x q", "h g z e p", "c n w t x", "z v y o d", "b c w u y"}
{"c", "u", "m", "r", "o", "y", "i", "p", "d", "j", "n", "v", "t", "x"}
Returns: 6
{"a i y d o", "t s k g e", "j u w i k", "u k l s j", "q s a c y", "q m d x a", "m s l h r", "s x q l n", "u r j s k", "e w v d p", "o l a b q", "f z g a m", "o g k b a", "c h g k t", "z v s n x", "z n b w c", "h p o u k", "t z o x m", "a w i v z", "u t v m y"}
{"x", "b", "u", "c", "h", "j", "t", "v", "d", "g", "k", "w", "y", "z", "a", "i", "m", "l", "n", "e"}
Returns: 6
{"v c k x f", "g f a m l", "c k z a w", "u q j n s", "v a t g k", "g c t v r", "c i t n z", "c d z e b", "m d n r j", "c a r z g", "a w i z h", "p x h m a", "m u g s h", "a x b g o", "a u k c y", "o i s m k", "u h b d a", "s l v o b", "f z t k q", "i z y c d"}
{"a", "y", "m", "n", "x", "b", "z", "e", "r", "h", "v", "p"}
Returns: 5
{"o c w q s", "p u z v o", "c j i k f", "k a t j y", "f z r q t", "e z g f r", "i l d n o", "j g t r u", "s d q t j", "x i a z l", "n l o p u", "m s d b j", "u l p s x", "l o q t m", "j c y m v", "t k h i x", "n o f p s", "m q g c r", "r m d t z", "b p i g y"}
{"j", "c", "k"}
Returns: 1
{ "a b c d ea", "a b c d eb", "a b c d ec", "a b c d ed", "a b c d ee", "a b c d ef", "a b c d eg", "a b c d eh", "a b c d ei", "a b c d ej", "a b c d ek", "a b c d el", "a b c d em", "a b c d en", "a b c d eo", "a b c d ep", "a b c d eq", "a b c d er", "a b c d es", "a b c d et" }
{ "ea", "eb", "ec", "ed", "ee", "ef", "eg", "eh", "ei", "ej", "ek", "el", "em", "en", "eo", "ep", "eq", "er", "es", "et" }
Returns: 20
{ "a i y d o", "t s k g e", "j u w i k", "u k l s j", "q s a c y", "q m d x a", "m s l h r", "s x q l n", "u r j s k", "e w v d p", "o l a b q", "f z g a m", "o g k b a", "c h g k t", "z v s n x", "z n b w c", "h p o u k", "t z o x m", "a w i v z", "u t v m y" }
{ "x", "b", "u", "c", "h", "j", "t", "v", "d", "g", "k", "w", "y", "z", "a", "i", "m", "l", "n", "e" }
Returns: 6
{ "aaaaaaaaa abbbbbbbb acccccccc adddddddd aeeeeeeee", "baaaaaaaa bbbbbbbbb bcccccccc bdddddddd beeeeeeee", "caaaaaaaa cbbbbbbbb ccccccccc cdddddddd ceeeeeeee", "daaaaaaaa dbbbbbbbb dcccccccc ddddddddd deeeeeeee", "eaaaaaaaa ebbbbbbbb ecccccccc edddddddd eeeeeeeee", "faaaaaaaa fbbbbbbbb fcccccccc fdddddddd feeeeeeee", "gaaaaaaaa gbbbbbbbb gcccccccc gdddddddd geeeeeeee", "haaaaaaaa hbbbbbbbb hcccccccc hdddddddd heeeeeeee", "iaaaaaaaa ibbbbbbbb icccccccc idddddddd ieeeeeeee", "jaaaaaaaa jbbbbbbbb jcccccccc jdddddddd jeeeeeeee", "kaaaaaaaa kbbbbbbbb kcccccccc kdddddddd keeeeeeee", "laaaaaaaa lbbbbbbbb lcccccccc ldddddddd leeeeeeee", "maaaaaaaa mbbbbbbbb mcccccccc mdddddddd meeeeeeee", "naaaaaaaa nbbbbbbbb ncccccccc ndddddddd neeeeeeee", "oaaaaaaaa obbbbbbbb occcccccc odddddddd oeeeeeeee", "paaaaaaaa pbbbbbbbb pcccccccc pdddddddd peeeeeeee", "qaaaaaaaa qbbbbbbbb qcccccccc qdddddddd qeeeeeeee", "raaaaaaaa rbbbbbbbb rcccccccc rdddddddd reeeeeeee", "saaaaaaaa sbbbbbbbb scccccccc sdddddddd seeeeeeee", "taaaaaaaa tbbbbbbbb tcccccccc tdddddddd teeeeeeee" }
{ "aaaaaaaaa", "baaaaaaaa", "caaaaaaaa", "daaaaaaaa", "eaaaaaaaa", "faaaaaaaa", "gaaaaaaaa", "haaaaaaaa", "iaaaaaaaa", "jaaaaaaaa", "kaaaaaaaa", "laaaaaaaa", "maaaaaaaa", "naaaaaaaa", "oaaaaaaaa", "paaaaaaaa", "qaaaaaaaa", "raaaaaaaa", "saaaaaaaa", "taaaaaaaa", "pbbbbbbbb", "qbbbbbbbb", "rbbbbbbbb", "sbbbbbbbb", "tbbbbbbbb" }
Returns: 20
{ "aaaaaaaaaaaaaa bbbbbbbbbbb cccccccc ddddd coloro", "aaaaaaaaaaaaaa bbbbbbbbbbb cccccccc ddddd colora", "aaaaaaaaaaaaaa bbbbbbbbbbb cccccccc ddddd colorp", "aaaaaaaaaaaaaa bbbbbbbbbbb cccccccc ddddd colorb", "aaaaaaaaaaaaaa bbbbbbbbbbb cccccccc ddddd colorq", "aaaaaaaaaaaaaa bbbbbbbbbbb cccccccc ddddd colorc", "aaaaaaaaaaaaaa bbbbbbbbbbb cccccccc ddddd colorr", "aaaaaaaaaaaaaa bbbbbbbbbbb cccccccc ddddd colord", "aaaaaaaaaaaaaa bbbbbbbbbbb cccccccc ddddd colors", "aaaaaaaaaaaaaa bbbbbbbbbbb cccccccc ddddd colore", "aaaaaaaaaaaaaa bbbbbbbbbbb cccccccc ddddd colort", "aaaaaaaaaaaaaa bbbbbbbbbbb cccccccc ddddd colorf", "aaaaaaaaaaaaaa bbbbbbbbbbb cccccccc ddddd colorn", "aaaaaaaaaaaaaa bbbbbbbbbbb cccccccc ddddd colorg", "aaaaaaaaaaaaaa bbbbbbbbbbb cccccccc ddddd colorm", "aaaaaaaaaaaaaa bbbbbbbbbbb cccccccc ddddd colorh", "aaaaaaaaaaaaaa bbbbbbbbbbb cccccccc ddddd colorl", "aaaaaaaaaaaaaa bbbbbbbbbbb cccccccc ddddd colori", "aaaaaaaaaaaaaa bbbbbbbbbbb cccccccc ddddd colork", "aaaaaaaaaaaaaa bbbbbbbbbbb cccccccc ddddd colorj" }
{ "colora", "colorb", "colorc", "colord", "colore", "colorf", "colorg", "colorh", "colori", "colorj", "colork", "colorl", "colorm", "colorn", "coloro", "colorp", "colorq", "colorr", "colors", "colort" }
Returns: 20
{ "uu tt vv mm yy", "t s k g e", "j u w i k", "u k l s j", "q s a c y", "q m d x a", "m s l h r", "s x q l n", "u r j s k", "e w v d p", "o l a b q", "f z g a m", "o g k b a", "c h g k t", "z v s n x", "z n b w c", "h p o u k", "t z o x m", "a w i v z", "a i y d o" }
{ "x", "b", "u", "c", "h", "j", "t", "v", "d", "g", "k", "w", "y", "z", "a", "i", "m", "l", "n", "e", "uu", "tt", "vv", "mm", "yy" }
Returns: 7
{ "a b c d e", "a f x y z", "b g x y z", "c h x y z", "d i x y z", "e j x y z" }
{ "a", "b", "c", "d", "e", "f", "g", "h", "i", "j" }
Returns: 5