Access a particular field in arbitrarily nested JSON data

{ "status": "200", "msg": "", "data": { "time": "1515580011", "video_info": [ { "announcement": "{"announcement_id":"6","name":"INS\u8d26\u53f7","icon":"http:\/\/liveme.cms.ksmobile.net\/live\/announcement\/2017-08-18_19:44:54\/ins.png","icon_new":"http:\/\/liveme.cms.ksmobile.net\/live\/announcement\/2017-10-20_22:24:38\/4.png","videoid":"15154610218328614178","content":"FOLLOW ME PLEASE","x_coordinate":"0.22","y_coordinate":"0.23"}", "announcement_shop": "", How do I grab the content “FOLLOW ME PLEASE” from this json? replay_data = raw_replay_data['data']['video_info'][0] announcement = replay_data['announcement'] This grab the everything withing [‘announcement’] and I can’t do [‘announcement’][‘content’]. What is the right way to do this? … Read more

python list by value not by reference

Let’s take an example a=['help', 'copyright', 'credits', 'license'] b=a b.append('XYZ') b ['help', 'copyright', 'credits', 'license', 'XYZ'] a ['help', 'copyright', 'credits', 'license', 'XYZ'] I wanted to append value in list ‘b’ but the value of list ‘a’ have also changed. I think I have little idea why its like this (python passes lists by reference). My … Read more