Skip to content

Instantly share code, notes, and snippets.

@nikojankovic
Created July 22, 2020 13:22
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save nikojankovic/a72f3e354d62c6aab3cc891cca33b8bc to your computer and use it in GitHub Desktop.
Save nikojankovic/a72f3e354d62c6aab3cc891cca33b8bc to your computer and use it in GitHub Desktop.
from itertools import product
policy_statuses = ['processing', 'active', 'pending-suspension', 'suspended', 'pending-cancellation', 'cancelled']
vehicle_statuses = ['processing', 'active', 'inactive']
inactive_user = [True, False]
failed_payments = [0,1,2,3]
expiring_user = [True, False]
cartesian_product = list(product(policy_statuses, vehicle_statuses, inactive_user, failed_payments, expiring_user))
dictionary = {}
for product in cartesian_product:
dictionary[product] = ''
print(dictionary)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment