title: Pig Latin Filter by list of strings
body: <p>I have a file containing urls
  and 3 files that contain urls that I want to see if they exist in the first file</p>
  
  <p>Example of first file is</p>
  
  <p><a href="http://www.url1.com/xxxx/xxx/xxx/xxx/" rel="nofollow">http://www.url1.com/xxxx/xxx/xxx/xxx/</a>,</p>
  
  <p><a href="http://www/urln.com/zzz/zzz/zzz/zzzz/zzzz/zz">http://www/urln.com/zzz/zzz/zzz/zzzz/zzzz/zz</a></p>
  
  <p>example of filter files:</p>
  
  <p><strong>filter1</strong></p>
  
  <p>url1.com</p>
  
  <p>url2.com</p>
  
  <p><strong>filter2</strong></p>
  
  <p>url5.com</p>
  
  <p>url6.com/ddfd</p>
  
  <p>urlx.org</p>
  
  <p>What I want to do is that on the same pass (if possible) check if <strong>any</strong> url from filter1 or <strong>any</strong> of the urls in filter 2 and so on is in the first file and if it is write the match to a file named after that filter( filter name irrelevant).
  Important each filter </p>
  
  <p>output will be something like this</p>
  
  <p>filter1.out</p>
  
  <p>http:// www.url1.com/xxx/sss
  http:// www.url2.com/xxx/xxxx/xxxx</p>