I’m wondering that how can you use enumerate() with for loop when you are printing the values and keys from the dictionary?
When I run the following code…:
def idx, key, value in enumerate(availability_table.items()):
…it will lead to the following error: “ValueError: not enough values to unpack (expected 3, got 2)”
Everything will work without enumerate and it will output the values and keys from the dictionary no problem but I’m so used to use enumerate with my loops that this is kinda grinding my gear. So I’m seeking some advice how to do this so it works or/and better.
Thank you in advance for the help or input