Python json pretty print Python json pretty print import json test = {'a': 1, 'b': 2} print(json.dumps(test, sort_keys=True, indent=2, separators=(',', ': '))) """ 아래와 같이 출력됩니다. { "a": 1, "b": 2 } """ Python 2017.07.03