title: Random generate a valid unicode character in Ruby
body: <p>How can I generate a random unicode string consisting of a given number of unicode characters in Ruby?</p>
  
  <p>The following works, but includes control characters (0x00-0x1F, etc.) for instance:</p>
  
  <pre><code>20.times.map{ Random.rand(0xFFFF).chr('UTF-8')}.join
  </code></pre>