#coding:utf-8
import urllib.request as urllib
response = urllib.urlopen("http://www.baidu.com/").read().decode('gb18030')
response2 = response[:]
print (response is response2)
print (response == response2)
response2 = (response2+"test")[:-4]
print (response is response2)
print (response == response2)
欢迎光临 Chinaunix (http://bbs.chinaunix.net/) | Powered by Discuz! X3.2 |