网络爬虫

2015-04-30 0 460
网络爬虫
# -*- coding: cp936 -*-
import WebCrawler
import time

url = input('设置入口url(例-->www.baidu.com): \n')
thNumber = int(input('设置线程数:'))    #之前类型未转换出bug
Maxdepth = int(input('最大搜索深度:'))

start = time.clock()
url = 'http://' + url
wc = WebCrawler.WebCrawler(thNumber, Maxdepth)
wc.Craw(url)
end = time.clock()

print("The function run time is: %0.02f senconds.\n" %(end - start))

遇见资源网 python 网络爬虫 http://www.ox520.com/15276.html

上一篇: 异常处理
常见问题

相关文章

发表评论
暂无评论
官方客服团队

为您解决烦忧 - 24小时在线 专业服务