Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #54841
| From | Virendra Tripathi <virendra.tripathi@maansystems.com> |
|---|---|
| Subject | Re: Convert namedtuple to dictionary |
| Date | 2013-09-26 17:13 +0000 |
| Newsgroups | comp.lang.python |
| Message-ID | <mailman.361.1380215641.18130.python-list@python.org> (permalink) |
Hi MRAB, Thanks. Learning a lot thanks to you guys. I should have mentioned that the data is dynamic, in the sense that 'brucelee' could be 'jackiechan' , the number of named tuples - i.e., 'brucelee(…)', could change as well, the next time data is pulled in. The format of the data would however remain the same. I am using @Tim Chase's solution for now. Your solution will also work but I think I'll need to create a fn to pull out the " n " values as in: ">>> n = brucelee(x=123, y=321)" Thanks, Virendra
Back to comp.lang.python | Previous | Next | Find similar | Unroll thread
Re: Convert namedtuple to dictionary Virendra Tripathi <virendra.tripathi@maansystems.com> - 2013-09-26 17:13 +0000
csiph-web