Skip to content

Instantly share code, notes, and snippets.

@Cherisea
Last active July 13, 2017 06:24
Show Gist options
  • Save Cherisea/e460d935ce49d5464db26853b0c8bf77 to your computer and use it in GitHub Desktop.
Save Cherisea/e460d935ce49d5464db26853b0c8bf77 to your computer and use it in GitHub Desktop.
web crwaler
import random
import urllib.request
def download_web_image(url):
num = random.randrange(1, 100)
full_name = str(num) + '.jpg'
urllib.request.urlretrieve(url, full_name)
download_web_image("http://pic.58pic.com/58pic/11/84/23/13A58PIC6ZC.jpg")
@Cherisea
Copy link
Author

first time I have got a dip of web crawler

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment