title: regex for extracting only alphabets and numbers in a string in R
body: <p>Hi I need a regex which extracts numbers and (numbers + alphabets) if present in a string.</p>
  
  <p>Ex: "4596 2B FC JAIN BHAWAN" --> I want "4596 2B" as my output</p>
  
  <pre><code>&gt; gsub("\\S([a-zA-Z])+\\S", "", "4596 2B FC JAIN BHAWAN")
  [1] "4596 2B FC  "
  </code></pre>
  
  <p>I do not understand why the above regex did not replace FC with ""</p>
  
  <p>Any help is appreciated. Thanks</p>