title: How to search for a particular string with in a regex group with in a single regex in Python?
body: <p>I am trying to match the word 'noun' with in the last group of my regex.</p>
  
  <p>So far I have:</p>
  
  <pre><code>tags = 'motocykl mutka 1 motorcycle bike moped 0 transportation openair noun'
  
  print re.search('(?P&lt;pol&gt;\D+)(?P&lt;d1&gt;\d)(?P&lt;eng&gt;\D+)(?P&lt;d2&gt;\d)(?P&lt;end&gt;\D+)', tags).group('end')
  </code></pre>
  
  <p>All I get is a string which is that last group:</p>
  
  <pre><code>transportation openair noun
  </code></pre>
  
  <p>I need to just get:</p>
  
  <pre><code>noun
  </code></pre>
  
  <p><strong>UPDATE:</strong></p>
  
  <p>I forgot to mention that 'noun' will not be showing up as the <strong><em>last</em></strong> word in some strings I will be running the regex against. For example:</p>
  
  <pre><code>tags = 'dźwig 1 crane 0 noun construction vehicle'
  tags = 'trycykl 1 tricycle 0 child noun transportation'
  </code></pre>
  
  <p><strong>Any ideas on how to do this with in a single regex?</strong></p>