Created
September 26, 2017 03:09
-
-
Save r-k-b/695d84e38f1e28acaf8f5494fcb16bec to your computer and use it in GitHub Desktop.
Quickly enumerate a human-readable Cartesian Product for some choices.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import itertools | |
| somelists = [ | |
| [ | |
| 'There is no last-seen catalog for this product', | |
| 'The last-seen category is the same as the current category', | |
| 'The last-seen category is different to the current category', | |
| ], | |
| [ | |
| 'The last-seen category matches to a BigCommerce category', | |
| 'The last-seen category does not match to a BigCommerce category', | |
| ], | |
| [ | |
| 'The current category matches to a BigCommerce category', | |
| 'The current category does not match to a BigCommerce category', | |
| ], | |
| [ | |
| 'The BigCommerce product has the last-seen category', | |
| 'The BigCommerce product does not have the last-seen category', | |
| ], | |
| [ | |
| 'The BigCommerce product has the current category', | |
| 'The BigCommerce product does not have the current category', | |
| ], | |
| ] | |
| for element in itertools.product(*somelists): | |
| print(element) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment