title: How to match pairs of characters using Regex?
body: <p>I have a variable containing a string. This string contains only alphabetic and numeric characters. This string also have a fixed length by <em>32</em> characters in length. How I can match using regular expressions if this string have only paired characters by length of <em>2</em>, <em>4</em>, <em>8</em>, <em>16</em>?</p>
  
  <p>For example, for similar to this strings:</p>
  
  <blockquote>
    <p>abcdefghijklmnopqrstuvwxyz012345</p>
  </blockquote>
  
  <p><code>Regex.IsMatch</code> must return <code>false</code>.</p>
  
  <p>But for strings similar to this:</p>
  
  <blockquote>
    <p><strong>aaaaaaaaaaaaaaaa</strong>5555555555555555</p>
  </blockquote>
  
  <p>this is a <em>16</em>-characters pairs;</p>
  
  <blockquote>
    <p><strong>aaaaaaaa</strong>55555555aaaaaaaa55555555</p>
  </blockquote>
  
  <p>this is a <em>8</em>-characters pairs;</p>
  
  <blockquote>
    <p><strong>aaaa</strong>5555aaaa5555aaaa5555aaaa5555</p>
  </blockquote>
  
  <p>this is a <em>4</em>-characters pairs;</p>
  
  <blockquote>
    <p><strong>aa</strong>55aa55aa55aa55aa55aa55aa55aa55</p>
  </blockquote>
  
  <p>this is a <em>2</em>-characters pairs -</p>
  
  <p><code>Regex.IsMatch</code> must return <code>true</code>.</p>