title: Python - Search for Word In Line, Count it, Add It
body: <p>I'm pretty sure I'm over thinking this and there's a simple outcome for it, but I just can't seem to put it all together.</p>
  
  <p>I'm looking for a kind of a search method. I'd like a Python script search a text file for a keyword and count how many lines it appears on. Though if the keyword comes up on a single line multiple times, I'd like to still only count it once. </p>
  
  <p>Long story short; If a keyboard comes up on a single line, I want it to count that line and add it to what will be a math equation.</p>
  
  <p>Any help is greatly appreciated! Thanks in advance.</p>