Pretty print json but keep inner arrays on one line python -
Pretty print json but keep inner arrays on one line python -
i pretty printing json in python using code:
json.dumps(json_output, indent=2, separators=(',', ': ')
this prints json like:
{ "rows_parsed": [ [ "a", "b", "c", "d" ], [ "e", "f", "g", "i" ], ] }
however, want print like:
{ "rows_parsed": [ ["a","b","c","d"], ["e","f","g","i"], ] }
how can maintain arrays in arrays on 1 line above?
python arrays json dictionary pretty-print
Comments
Post a Comment