Could anybody give better example to understand json encode and decode
The JSON encode is the same as json.dumps(). This changes a python object to a JSON object and the decode is the same as json. loads(). This changes the JSON object back to a python object, usually a dictionary.