Python how to find correct result in string
<p>I'm using Occidentalis v0.2 and calling modprobe with a python script to read out temperatures from one DS18B20!</p>

<p>Im new to python as well so bare with me, this is a small part of my code:</p>

<pre><code>with open(path, "r") as f:
  contentArray = []
  for line in f:
    contentArray.append (line)
f.close

s = contentArray[0]
if s.find('YES'):
  return contentArray[0]
else:
  return 88
</code></pre>

<p>Example: contentArray[0] can give results as
68 01 4b 46 7f ff 0c 10 05 : crc=3e NO
or
68 01 4b 46 7f ff 08 10 05 : crc=05 YES</p>

<p>If the above code is wrong, how do I do to find the YES? because this states
correct CRC. If I have a yes, I acctually want to return contentArray[1] (who 
contain the correct temperature value).</p>
