On Tue, 09 Oct 2012 04:59:49 -0700, argbsk wrote: > below is the text file i have How to create Facility as a key and then > assign multiple values to it
To use Facility as a key in a dict: d = {} d['Facility'] = 'ham' Note that keys are case-sensitive, so that 'Facility', 'facility', 'FACILITY' and 'FaCiLiTy' are all different. To have multiple values assigned to a key, use a list: d['Facility'] = ['ham', 'spam', 'cheese', 'eggs'] d['Facility'].append('tomato') -- Steven -- http://mail.python.org/mailman/listinfo/python-list