标签:for upd www. lin users request write line hand
import hashlib import requests import sys import json def get(i): res=requests.get(‘http://www.qlcoder.com/train/handsomerank?_token=&user=&checkcode={}‘. format(i)) if res.status_code!=200: sys.exit(1) def set(i,result): result=json.dumps(result) with open(r‘C:\Users\hzqt2\Desktop\test.txt‘,‘a‘) as f: f.writelines(str(i)+‘ ‘+str(result)+‘\r\n‘) result={111:3299700,128:599977,131:2450747,145:391019,153:761138,161:3176684,171:1003551,207:203924,217:226370} for i in range(22,1001): if i in result.keys(): get(result[i]) continue x = 0 while 1: md5=hashlib.md5(‘20190106slqt‘+str(i)+str(x)).hexdigest() #print(md5,md5[0:6]) if md5[0:6]==‘000000‘: result.update({i:x}) print i,x set(i, x) get(x) if i<100: result.update({i*10+int(str(x)[0]): int(str(x)[1:])}) set(i*10+int(str(x)[0]),int(str(x)[1:])) break # x+=1
标签:for upd www. lin users request write line hand
原文地址:https://www.cnblogs.com/slqt/p/10228956.html