What do you want to save?
Add Code snippet
New code examples
-
Other 2022-01-22 19:36:19
web scraping print all p and h2 tags
import requests from bs4 import BeautifulSoup url = 'https://www.python.org/' reqs = requests.get(url) soup = BeautifulSoup(reqs.text, 'lxml') print("List of all the h1, h2, h3 :") for heading in soup.find_all(["h1", "h2", &q... Add solution -
Other 2021-11-18 15:11:23
data-reactid beautifulsoup
from bs4 import BeautifulSoup import requests import sys from datetime import datetime, timedelta import pandas as pd code = input("Enter the NYSE stock symbol: ") #Your Choice Stock source = requests.get('https://finance.yahoo.com/quote/'+ co... Add solution -
Other 2021-11-17 07:47:26
https connection pool max retries exceeded
import requests from requests.adapters import HTTPAdapter from requests.packages.urllib3.util.retry import Retry session = requests.Session() retry = Retry(connect=3, backoff_factor=0.5) adapter = HTTPAdapter(max_retries=retry) session.mount('http://', ... Add solution -
Python 2021-11-15 22:32:18
instagram username checker
import requests import random import time import urllib3 urllib3.disable_warnings(urllib3.exceptions.InsecureRequestWarning) f = open("username_text_file.txt", "r") # create a text file with the usernames you want to check data = f.re... Add solution -
Python 2021-11-13 05:41:21
multipart/form data multipart encoder python
from requests_toolbelt import MultipartEncoder import requests m = MultipartEncoder( fields={'field0': 'value', 'field1': 'value', 'field2': ('filename', open('file.py', 'rb'), 'text/plain')} ) r = requests.post('http://httpbin.org/p... Add solution