title: Regular expression to remove duplicates from comma separated string
body: <p>I have following string:</p>
  
  <pre><code>'C,2,1,2,3,1'
  </code></pre>
  
  <p>I need a regular expression to remove duplicates and the result string should be like this:</p>
  
  <pre><code>'C,2,1,3'
  </code></pre>