title: Using Keyword to Print Sentence
body: <p>I am trying to write a program to take a list of keywords and print out the sentence that contains such word from a website a user enters. Right now my output is printing out a whole lot of extra stuff such as symbols, I want it to just print the sentence for each occurence. How do I go about that?
  code so far:</p>
  <pre><code>#Import Packages
  import requests
  from bs4 import BeautifulSoup
  import urllib.request as ul
  url = input('Enter URL:')
  reg= requests.get(url,allow_redirects=False) 
  soup = BeautifulSoup(req.content, &quot;lxml&quot;)
  words = [&quot;technology&quot;,&quot;wireless&quot;]
  
  for word in words:
      print(word, soup.find(text=lambda text: text and word in text))
  </code></pre>