0

I am learning Maya Python as part of the art school program but since the teacher is not very competence so I am looking for help with this homework.

So the task is basically: Create 2 dictionaries and constrains the values of one key to the other. But I should see one driver and one driven object per key

def ConstraintDict():

category = {
    "brand",
    "model",
    "year"
}


car = {
    "Mazada",
    "626",
    "1994"
}

brand should be driven by Mazda

model should be driven by 626

year driven by 1994

I have been trying to search for a solution and haven't found a proper answer yet.

Please help me out with this

Brad Solomon
  • 38,521
  • 31
  • 149
  • 235
Rey1000
  • 3
  • 1
  • Any reason you made `category` and `car` as sets? construct them as lists and do `dict(zip(category, car))` – Chris Aug 07 '19 at 02:28
  • For me you are trying to solve something that should be using class. I would have created a Human class and a Vehicle class where I would have a method for assigning Human – DrWeeny Aug 11 '19 at 14:37

0 Answers0