import requests,sys
from bs4 import BeautifulSoup
def gethml(url):
rr=requests.get(url)
s=rr.content
s.decode("ISO-8859-1")
return s
html=gethml(url)
soup =BeautifulSoup(html, "lxml")
for itema in soup.select(".cname"):
import random,string
passwd="https://jobs.51job.com/all/"
num=string.digits
for i in range(10):
passwd+=random.choice(num)
passwd+=".html"
print (passwd)