import re,urllib
aa="http://dict.youdao.com/search?tab=chn&keyfrom=dict.top&q="
print ("input q! to exit ")
while 1:
word=raw_input(">>>")
if word=="q!":
exit()
else:
word=word.replace(' ','+')
url=aa+word
s=urllib.urlopen(url).read()
comm=re.compile(r'<td class="dttitle2"><font color="#013694"><b>(.*?)<\/b><\/font><\/td>')
tem=comm.findall(s)
com=re.compile('<td class="attributem1web">(.*?)</td>',re.S|re.M|re.I)
result=com.findall(s)
if tem:
for i in tem:
temp=i.decode('utf8').encode('cp936')
print (temp)
print '\n'
else:
print ("no such word\n")
机械节能产品生产企业官网模板...
大气智能家居家具装修装饰类企业通用网站模板...
礼品公司网站模板
宽屏简约大气婚纱摄影影楼模板...
蓝白WAP手机综合医院类整站源码(独立后台)...苏ICP备2024110244号-2 苏公网安备32050702011978号 增值电信业务经营许可证编号:苏B2-20251499 | Copyright 2018 - 2025 源码网商城 (www.ymwmall.com) 版权所有