Aug-08-2018, 11:12 AM
You didn't get my point. You can't give meaningful variable name in unpack:
name, address, phone = values
unless you already knew which element each item in values represents, and you can get this information only through counting. Also this unpack statement may need to be modified each time the form was modified.
If values is a dictionary, you can write (suppose 'address' is a key):
print(values['address'])
No counting is required and no changes from now on.
name, address, phone = values
unless you already knew which element each item in values represents, and you can get this information only through counting. Also this unpack statement may need to be modified each time the form was modified.
If values is a dictionary, you can write (suppose 'address' is a key):
print(values['address'])
No counting is required and no changes from now on.