Im building a tool to check a list of Instagram username and tell if they are available. So for first underestand web scraping, i tried to check if “(” is in the title of the instagram page of @paris
import requests
from bs4 import BeautifulSoup
url = requests.get('https://www.instagram.com/paris/')
soup = BeautifulSoup ( url.content , "html.parser" )
title = soup.find('title')
print(title)
if '(' in title:
print("Y")
So the page actually contain a ( inside is title but when i try the condition “if ‘(‘ in title” i doesn’t print Y so it doesn’t find the ( in “title”
Can anyone give me a way to make this code actually work, it’s gonna be important for my project
(sorry for my bad english, im french)
user25653727 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.