title: optimal way to count string tags using python
body: <p>so I have this list: </p>
  
  <pre><code>tokens = ['&lt;greeting&gt;', 'Hello World!', '&lt;/greeting&gt;']
  </code></pre>
  
  <p>the task is to count the number of strings that have XML tags. what I have so far (that works) is this:</p>
  
  <pre><code>tokens = ['&lt;greeting&gt;', 'Hello World!', '&lt;/greeting&gt;']
  count = 0
  
  for i in range(len(tokens)):
      if tokens[i].find('&gt;') &gt;1: 
          print(tokens[i])
          count += 1
          print(count)
      else:
          count += 0 
  </code></pre>
  
  <p>what puzzles me is that I'm inclined in using the following line for the if statement</p>
  
  <pre><code>  if tokens[i].find('&gt;') == True:
  </code></pre>
  
  <p>but it won't work. 
  what's the optimal way of writing this loop, in your opinion?
  many thanks!
  alex.</p>