How to convert an string to json in Python
Question: I'm trying to convert an string into `json` output from **local Data** or
Those datas from `BeautifulSoup` output as `Json`.for example:

    
    
    #! /usr/bin/python
    
    data = ('Hello')
    print data
    

and i need to convert this `Hello` as json output.

How can do that?

is this possible?


Answer: Check out the json module in Python
<https://docs.python.org/2/library/json.html>

    
    
    import json
    json.dumps({"hello": 0}, sort_keys=True)
    

