立即学习:https://edu.csdn.net/course/play/24454/306761?utm_source=blogtoedu
url headers
word=input('输入关键字:')
data={'kw':word}#传入request
response = requests.(get)/post(url=,headers)
##text格式储存,page_text=response.text
##josn方法储存,必须确认响应的数据返回的是json从 response heard中查看
dic_obj = response.json()
filename=word+'.json'
fp = open (filename,'w',encoding='utf-8')
json.dump(dic_obj,fp=fp,ensure_ascii=False)