On Thu, Jun 9, 2022 at 11:44 AM Dave <d...@looktowindward.com> wrote: > > Hi, > > Before I write my own I wondering if anyone knows of a function that will > print a nicely formatted dictionary? > > By nicely formatted I mean not all on one line!
>>> import json >>> d = {'John': 'Cleese', 'Eric': "Idle", 'Micheal': 'Palin'} >>> print(json.dumps(d, indent=4)) { "John": "Cleese", "Eric": "Idle", "Micheal": "Palin" } -- https://mail.python.org/mailman/listinfo/python-list