from collections import namedtuple Person = namedtuple('Person', ['name', 'age']) jake = Person('jake', 22) print(jake) print(jake.name, jake.age)
To embed this project on your website, copy the following code and paste it into your website's HTML: