title: How can i download all types of file in python with request library
body: <p>I am building the crawler in python and i have the list of <code>href</code> from the page.</p>
  
  <p>Now i have the list of file extensions to download like</p>
  
  <p><code>list = ['zip','rar','pdf','mp3']</code></p>
  
  <p>How can i save the files from that url to local directory using python</p>
  
  <p>EDIT:</p>
  
  <pre><code>import urllib2
  from bs4 import BeautifulSoup
  
  url = "http://www.example.com/downlaod"
  
  site = urllib2.urlopen(url)
  html = site.read()
  soup = BeautifulSoup(html)
  
  list_urls = soup.find_all('a')
  
  print list_urls[6]
  </code></pre>