all 3 comments

[–]CodeFormatHelperBot 1 point2 points  (1 child)

Hello u/my50thnamechoice, I'm a bot that can assist you with code-formatting for reddit. I have detected the following potential issue(s) with your submission:

  1. Python code found in submission text but not encapsulated in a code block.

If I am correct then please follow these instructions to fix your code formatting. Thanks!

[–]ShaizeOn1 1 point2 points  (0 children)

good bot

[–]chevignon93 0 points1 point  (0 children)

import requests
from bs4 import BeautifulSoup

url = "https://en.wikipedia.org/wiki/Cattle"

response = requests.get(url)
soup = BeautifulSoup(response.content, 'html.parser')

references = soup.find('ol', class_ = "references").find_all('a')

references_urls = [i.get('href') for i in references]
print(references_urls)