title: Filter a list of strings based on several possible endings
body: <p>I don't know any python but I need to customize a script a little bit.
  There are strings parsed in the script and put to a list (I guess).
  Then these strings are filtered based on whether they start with &quot;http&quot;. What I want to add is a filter based on their file extension as well. All links ending on <code>html</code> or <code>xml</code> shall be filtered.</p>
  <p>This is the code that filters all hyperlinks:</p>
  <pre><code>links = filter (lambda x:x.startswith(&quot;http://&quot;) , links) 
  </code></pre>
  <p>I don't know the proper syntax to put an OR operator for something like <code>.endswith(&quot;.html) OR .endswith(&quot;xml&quot;)</code></p>
  <p>I know this would filter all links ending on <code>.html</code> but I also need the <code>.xml</code> links.</p>
  <pre><code>links = filter (lambda x:x.startswith(&quot;http://&quot;) , links) 
  links = filter (lambda x:x.endswith(&quot;.html&quot;) , links) 
  </code></pre>