Pretty print json but keep inner arrays on one line python -


I am printing a lot of json in Python using this code:

  json.dumps (json_output, indent = 2, separator = (',', ':')   

It prints like my JSON:

 < code> {"rows_parsed": [[["A", "B", "C", "D"], ["E", "F", "G", "I"],]} <[ >  

, I want to print it:

  {"rows_parsed": [["a", "b", "c", "d"], ["E", "f", "jee", "i"],]}   

How can I put arrays in a row like one above?

>

is an NPM module that does this, which can be translated into Python (or externally called).

< / Div>

Comments

  1. सी कोडर्स के लिए भाषा नमूना कार्यक्रम
    नाग खेल सी कोड स्निपेट

    ReplyDelete

Post a Comment

Popular posts from this blog

php - PDO bindParam() fatal error -

logging - How can I log both the Request.InputStream and Response.OutputStream traffic in my ASP.NET MVC3 Application for specific Actions? -

java - Why my included JSP file won't get processed correctly? -