title: How to implement "unescape" in Scala?
body: <p>This is a follow-up to my previous <a href="https://stackoverflow.com/questions/21855816/how-to-do-escaping-idiomatically-in-scala">question</a></p>
  
  <p>Thanks to the answers I realized that the <code>escape</code> function is <em>actually</em> a <code>flatMap</code> with argument <code>f:Char =&gt; Seq[Char]</code> to map escaped characters to escaping sequences (see the answers).</p>
  
  <p>Now I wonder how to implement <code>unescape</code> as a <em>reverse</em> operation to <code>escape</code>. I guess tt should be a reverse to <code>flatMap</code> with argument <code>f:Seq[Char] =&gt; Char</code>. Does it make sense ? How would you suggest implement <code>unescape</code> ?</p>